aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhil Blundell <philb@gnu.org>1998-06-11 13:23:40 +0000
committerPhil Blundell <philb@gnu.org>1998-06-11 13:23:40 +0000
commite512951281999b560cf684ecfdd5dcd8f34e36ad (patch)
tree7e0c8b0f552dbbcbc16dd15d68c8a022ca2e7d47 /hostname.c
parentBe robust, allow to skip leading zero as RH4.2 does. (diff)
downloadnet-tools-e512951281999b560cf684ecfdd5dcd8f34e36ad.tar.gz
net-tools-e512951281999b560cf684ecfdd5dcd8f34e36ad.tar.bz2
net-tools-e512951281999b560cf684ecfdd5dcd8f34e36ad.zip
Fix uninitialised variable (was causing problems on SPARC apparently)
(From Aron Griffis <agriffis@coat.com>)
Diffstat (limited to 'hostname.c')
-rw-r--r--hostname.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hostname.c b/hostname.c
index 1a344a3..485f56b 100644
--- a/hostname.c
+++ b/hostname.c
@@ -240,7 +240,7 @@ int main(int argc, char **argv)
char type='\0';
int option_index = 0;
int what = 0;
- char myname[MAXHOSTNAMELEN+1];
+ char myname[MAXHOSTNAMELEN+1] = { 0 };
char *file=NULL;
static const struct option long_options[] =