Date: Sun, 3 Jul 2005 01:11:25 GMT From: Phil Oleson <oz@nixil.net> To: freebsd-bugs@FreeBSD.org Subject: Re: bin/79418: [patch] libedit sync from netbsd cvs Message-ID: <200507030111.j631BPa5020607@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/79418; it has been noted by GNATS. From: Phil Oleson <oz@nixil.net> To: FreeBSD-gnats-submit@FreeBSD.org, freebsd-bugs@FreeBSD.org Cc: Subject: Re: bin/79418: [patch] libedit sync from netbsd cvs Date: Tue, 05 Apr 2005 03:00:17 -0600 This is a multi-part message in MIME format. --------------060902030201060704010601 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Here are patches to port the rest of the userspace apps that use libevent to use the H_SETSIZE flag rather than H_EVENT, which will be eliminated with the upgrade of libevent. This should allow buildworld to compile clean after the libevent patch is applied. Phil. -- It's a frail sad line between optimism and delusion. --------------060902030201060704010601 Content-Type: text/plain; name="cdcontrol.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="cdcontrol.patch" Index: src/usr.sbin/cdcontrol/cdcontrol.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/cdcontrol/cdcontrol.c,v retrieving revision 1.48 diff -u -r1.48 cdcontrol.c --- src/usr.sbin/cdcontrol/cdcontrol.c 1 Apr 2004 16:37:46 -0000 1.48 +++ src/usr.sbin/cdcontrol/cdcontrol.c 5 Apr 2005 08:45:00 -0000 @@ -1130,7 +1130,7 @@ el = el_init("cdcontrol", stdin, stdout, stderr); hist = history_init(); - history(hist, &he, H_EVENT, 100); + history(hist, &he, H_SETSIZE, 100); el_set(el, EL_HIST, history, hist); el_set(el, EL_EDITOR, "emacs"); el_set(el, EL_PROMPT, cdcontrol_prompt); --------------060902030201060704010601 Content-Type: text/plain; name="fsdb.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="fsdb.patch" Index: src/sbin/fsdb/fsdb.c =================================================================== RCS file: /home/ncvs/src/sbin/fsdb/fsdb.c,v retrieving revision 1.29 diff -u -r1.29 fsdb.c --- src/sbin/fsdb/fsdb.c 9 Oct 2004 15:56:34 -0000 1.29 +++ src/sbin/fsdb/fsdb.c 5 Apr 2005 08:41:50 -0000 @@ -223,7 +223,7 @@ printactive(0); hist = history_init(); - history(hist, &he, H_EVENT, 100); /* 100 elt history buffer */ + history(hist, &he, H_SETSIZE, 100); /* 100 elt history buffer */ elptr = el_init("fsdb", stdin, stdout, stderr); el_set(elptr, EL_EDITOR, "emacs"); @@ -243,7 +243,7 @@ * el_parse returns -1 to signal that it's not been handled * internally. */ - if (el_parse(elptr, cmd_argc, cmd_argv) != -1) + if (el_parse(elptr, cmd_argc, (const char **)cmd_argv) != -1) continue; if (cmd_argc) { known = 0; --------------060902030201060704010601 Content-Type: text/plain; name="lpr-lpc.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="lpr-lpc.patch" Index: src/usr.sbin/lpr/lpc/lpc.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/lpr/lpc/lpc.c,v retrieving revision 1.30 diff -u -r1.30 lpc.c --- src/usr.sbin/lpr/lpc/lpc.c 22 Feb 2005 02:56:42 -0000 1.30 +++ src/usr.sbin/lpr/lpc/lpc.c 5 Apr 2005 08:43:31 -0000 @@ -167,7 +167,7 @@ if (!el) { el = el_init("lpc", stdin, stdout, stderr); hist = history_init(); - history(hist, &he, H_EVENT, 100); + history(hist, &he, H_SETSIZE, 100); el_set(el, EL_HIST, history, hist); el_set(el, EL_EDITOR, "emacs"); el_set(el, EL_PROMPT, lpc_prompt); --------------060902030201060704010601 Content-Type: text/plain; name="sh.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="sh.patch" Index: src/bin/sh/histedit.c =================================================================== RCS file: /home/ncvs/src/bin/sh/histedit.c,v retrieving revision 1.26 diff -u -r1.26 histedit.c --- src/bin/sh/histedit.c 6 Apr 2004 20:06:51 -0000 1.26 +++ src/bin/sh/histedit.c 5 Apr 2005 08:40:14 -0000 @@ -156,7 +156,7 @@ if (hs == NULL || *hs == '\0' || (histsize = atoi(hs)) < 0) histsize = 100; - history(hist, &he, H_EVENT, histsize); + history(hist, &he, H_SETSIZE, histsize); } } @@ -318,7 +318,7 @@ if (editor) { int fd; INTOFF; /* easier */ - sprintf(editfile, "%s/_shXXXXXX", _PATH_TMP); + snprintf(editfile, sizeof(editfile), "%s_shXXXXXX", _PATH_TMP); if ((fd = mkstemp(editfile)) < 0) error("can't create temporary file %s", editfile); if ((efp = fdopen(fd, "w")) == NULL) { --------------060902030201060704010601 Content-Type: text/plain; name="tftp.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="tftp.patch" Index: src/usr.bin/tftp/main.c =================================================================== RCS file: /home/ncvs/src/usr.bin/tftp/main.c,v retrieving revision 1.21 diff -u -r1.21 main.c --- src/usr.bin/tftp/main.c 12 Oct 2003 00:27:55 -0000 1.21 +++ src/usr.bin/tftp/main.c 5 Apr 2005 08:42:56 -0000 @@ -635,7 +635,7 @@ if (vrbose) { el = el_init("tftp", stdin, stdout, stderr); hist = history_init(); - history(hist, &he, H_EVENT, 100); + history(hist, &he, H_SETSIZE, 100); el_set(el, EL_HIST, history, hist); el_set(el, EL_EDITOR, "emacs"); el_set(el, EL_PROMPT, command_prompt); --------------060902030201060704010601 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ freebsd-bugs@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-bugs To unsubscribe, send any mail to "freebsd-bugs-unsubscribe@freebsd.org" --------------060902030201060704010601--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200507030111.j631BPa5020607>