freebsd-ports/x11/rxvt-devel/files/utmp_patch-src::logging.c
Martin Wilke c40a93cf47 - Fix build on head
PR:		143954
Submitted by:	bf <bf1783@gmail.com>
Approved by:	maintainer
2010-05-09 10:06:04 +00:00

12 lines
407 B
C

--- src/logging.c
+++ src/logging.c
@@ -82,7 +82,8 @@
else if (sscanf(pty, "pts/%d", &i) == 1)
sprintf(ut_id, "vt%02x", (i & 0xff)); /* sysv naming */
#endif
- else if (STRNCMP(pty, "pty", 3) && STRNCMP(pty, "tty", 3)) {
+ else if (STRNCMP(pty, "pty", 3) && STRNCMP(pty, "tty", 3) &&
+ STRNCMP(pty, "pts/", 4)) {
rxvt_print_error("can't parse tty name \"%s\"", pty);
return;
}