From 3d1542ebf7fd234dc9c1bfe57dcfbda9e1141ca2 Mon Sep 17 00:00:00 2001 From: grog Date: Wed, 21 Sep 2005 05:20:03 +0000 Subject: Remove one possible way of shooting yourself in the foot. Submitted by: Ulrich Sperlein --- usr.sbin/asf/asf.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'usr.sbin/asf') diff --git a/usr.sbin/asf/asf.c b/usr.sbin/asf/asf.c index 704fcac..fddc363 100644 --- a/usr.sbin/asf/asf.c +++ b/usr.sbin/asf/asf.c @@ -247,6 +247,8 @@ main(int argc, char *argv[]) quad_t bssaddr; tokens = tokenize(buf, token, MAXTOKEN); + if (tokens < 4) + continue; base = strtoll(token[2], NULL, 16); if (!dofind) { strcpy(basetoken, token[4]); @@ -261,7 +263,7 @@ main(int argc, char *argv[]) debugname); } else { char *modpath; - + modpath = findmodule(strdup(modules_path), token[4]); if (modpath == NULL) continue; @@ -306,7 +308,7 @@ main(int argc, char *argv[]) textaddr); } else { char *modpath; - + modpath = findmodule(strdup(modules_path), token[4]); if (modpath == NULL) continue; -- cgit v1.1