diff options
author | Andrew Waterman <waterman@cs.berkeley.edu> | 2015-01-09 17:41:43 -0800 |
---|---|---|
committer | Andrew Waterman <waterman@cs.berkeley.edu> | 2015-01-09 17:41:43 -0800 |
commit | b029a9c67b345bb1133e8e33dee6bb5c42558478 (patch) | |
tree | 6c739cc54ed0d725d15a02a7bd641721f1676b05 /spike_main/xspike.cc | |
parent | bd97b5c9fddd30cafd5e84b229e3cf4a29d427ad (diff) | |
download | spike-b029a9c67b345bb1133e8e33dee6bb5c42558478.zip spike-b029a9c67b345bb1133e8e33dee6bb5c42558478.tar.gz spike-b029a9c67b345bb1133e8e33dee6bb5c42558478.tar.bz2 |
Use PATH_MAX instead of NAME_MAX
Diffstat (limited to 'spike_main/xspike.cc')
-rw-r--r-- | spike_main/xspike.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/spike_main/xspike.cc b/spike_main/xspike.cc index 4331dbe..f8c8ca7 100644 --- a/spike_main/xspike.cc +++ b/spike_main/xspike.cc @@ -90,7 +90,7 @@ static pid_t fork_xterm(int* tty_fd) return -1; } - char tty[NAME_MAX]; + char tty[PATH_MAX]; ssize_t ttylen = read(fds[0], tty, sizeof(tty)); if (ttylen <= 1 || tty[ttylen-1] != '\n') return -1; |