summaryrefslogtreecommitdiff
path: root/auth-rhosts.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2003-05-18 20:53:10 +1000
committerDamien Miller <djm@mindrot.org>2003-05-18 20:53:10 +1000
commita9825785e864fa795d4b39d99d14bc6f9995a7dc (patch)
tree36ec0e16621ac6fc3078a4f145a11b6256883758 /auth-rhosts.c
parent7e1bbc55af32d8f5d81200323198c65b548faaad (diff)
- itojun@cvs.openbsd.org 2003/05/17 03:25:58
[auth-rhosts.c] just in case, put numbers to sscanf %s arg.
Diffstat (limited to 'auth-rhosts.c')
-rw-r--r--auth-rhosts.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/auth-rhosts.c b/auth-rhosts.c
index de2cb67f3..a38478108 100644
--- a/auth-rhosts.c
+++ b/auth-rhosts.c
@@ -14,7 +14,7 @@
14 */ 14 */
15 15
16#include "includes.h" 16#include "includes.h"
17RCSID("$OpenBSD: auth-rhosts.c,v 1.29 2003/04/08 20:21:28 itojun Exp $"); 17RCSID("$OpenBSD: auth-rhosts.c,v 1.30 2003/05/17 03:25:58 itojun Exp $");
18 18
19#include "packet.h" 19#include "packet.h"
20#include "uidswap.h" 20#include "uidswap.h"
@@ -68,7 +68,8 @@ check_rhosts_file(const char *filename, const char *hostname,
68 * This should be safe because each buffer is as big as the 68 * This should be safe because each buffer is as big as the
69 * whole string, and thus cannot be overwritten. 69 * whole string, and thus cannot be overwritten.
70 */ 70 */
71 switch (sscanf(buf, "%s %s %s", hostbuf, userbuf, dummy)) { 71 switch (sscanf(buf, "%1023s %1023s %1023s", hostbuf, userbuf,
72 dummy)) {
72 case 0: 73 case 0:
73 auth_debug_add("Found empty line in %.100s.", filename); 74 auth_debug_add("Found empty line in %.100s.", filename);
74 continue; 75 continue;