diff options
author | Kris Kennaway <kris@FreeBSD.org> | 2003-06-13 21:36:31 +0000 |
---|---|---|
committer | Kris Kennaway <kris@FreeBSD.org> | 2003-06-13 21:36:31 +0000 |
commit | 9a6dbead976c15f939936ac32c50c7d38a5a6a71 (patch) | |
tree | 0118b3c48df9aada08a0f2fdd67b90cd9a4c8ff0 /print/mpage/files/patch-mpage_c | |
parent | Use proxy/socks settings when registering setiathome (diff) |
Be more careful with string buffers and temporary files. Bump PORTREVISION.
Obtained from: OpenBSD
Notes
Notes:
svn path=/head/; revision=82956
Diffstat (limited to 'print/mpage/files/patch-mpage_c')
-rw-r--r-- | print/mpage/files/patch-mpage_c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/print/mpage/files/patch-mpage_c b/print/mpage/files/patch-mpage_c new file mode 100644 index 000000000000..e93d618d48ea --- /dev/null +++ b/print/mpage/files/patch-mpage_c @@ -0,0 +1,16 @@ +$OpenBSD: patch-mpage_c,v 1.1 2002/07/07 17:03:37 naddy Exp $ +--- mpage.c.orig Tue Nov 13 18:04:46 2001 ++++ mpage.c Sun May 19 01:00:14 2002 +@@ -74,10 +74,10 @@ char **argv; + */ + if (doprint) { + if (printque != NULL) +- (void) sprintf(outcommand, "%s %s%s", ++ (void) snprintf(outcommand, sizeof(outcommand), "%s %s%s", + printprog, printarg, printque); + else +- (void) strcpy(outcommand, printprog); ++ (void) strlcpy(outcommand, printprog, sizeof(outcommand)); + if ((outfd = popen(outcommand, "w")) == NULL) { + fprintf(stderr, "%s: cannot create pipe for '%s'\n", + MPAGE, outcommand); |