summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Janzen <pjanzen@cvs.openbsd.org>2001-03-09 08:36:25 +0000
committerPaul Janzen <pjanzen@cvs.openbsd.org>2001-03-09 08:36:25 +0000
commit45dc7970d9aae9fac2bcd269c318cfee62e86a42 (patch)
tree13cdcda95e0f604b8e2e517204dac6ff4d915c78
parent791d1ca6eb0ce3418e2c338468beb17701b68cec (diff)
resize a buffer for long usernames; ianm@cit.uws.edu.au
-rw-r--r--games/sail/lo_main.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/games/sail/lo_main.c b/games/sail/lo_main.c
index 8d09e281caf..ea79e0e8b6d 100644
--- a/games/sail/lo_main.c
+++ b/games/sail/lo_main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: lo_main.c,v 1.2 1999/01/18 06:20:52 pjanzen Exp $ */
+/* $OpenBSD: lo_main.c,v 1.3 2001/03/09 08:36:24 pjanzen Exp $ */
/* $NetBSD: lo_main.c,v 1.3 1995/04/22 10:36:59 cgd Exp $ */
/*
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)lo_main.c 8.2 (Berkeley) 4/28/95";
#else
-static char rcsid[] = "$OpenBSD: lo_main.c,v 1.2 1999/01/18 06:20:52 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: lo_main.c,v 1.3 2001/03/09 08:36:24 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -47,6 +47,7 @@ static char rcsid[] = "$OpenBSD: lo_main.c,v 1.2 1999/01/18 06:20:52 pjanzen Exp
*
* -l force a long listing (print out real usernames)
*/
+#include <sys/param.h>
#include <sys/types.h>
#include <pwd.h>
#include "extern.h"
@@ -62,7 +63,7 @@ int
lo_main()
{
FILE *fp;
- char sbuf[32];
+ char sbuf[20+MAXLOGNAME];
int n = 0, people;
struct passwd *pass;
struct logs log;