diff options
author | Jilles Tjoelker <jilles@FreeBSD.org> | 2015-04-26 21:34:55 +0000 |
---|---|---|
committer | Jilles Tjoelker <jilles@FreeBSD.org> | 2015-04-26 21:34:55 +0000 |
commit | c3210060864218b6d5b26cfcfb50eab1badac1cb (patch) | |
tree | a2b0d6dfd55b3654f0314d9cdc706bcd934027bb | |
parent | a5e0fa4063cf3b42e8392376c3ba09b528f570a8 (diff) | |
download | src-c3210060864218b6d5b26cfcfb50eab1badac1cb.tar.gz src-c3210060864218b6d5b26cfcfb50eab1badac1cb.zip |
hexdump: Don't use uninitialized struct stat.
Notes
Notes:
svn path=/head/; revision=282041
-rw-r--r-- | usr.bin/hexdump/display.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/hexdump/display.c b/usr.bin/hexdump/display.c index a5f2a4799e7a..4ff33080780b 100644 --- a/usr.bin/hexdump/display.c +++ b/usr.bin/hexdump/display.c @@ -380,7 +380,7 @@ doskip(const char *fname, int statok) return; } } - if (S_ISREG(sb.st_mode)) { + if (statok && S_ISREG(sb.st_mode)) { if (fseeko(stdin, skip, SEEK_SET)) err(1, "%s", fname); address += skip; |