diff options
author | Eric Andersen | 2000-10-12 22:30:31 +0000 |
---|---|---|
committer | Eric Andersen | 2000-10-12 22:30:31 +0000 |
commit | 0d5835a7674e8f36a5669e567be32d53dff401ac (patch) | |
tree | 3c1d3bf709d7b38dbc74323c5eb2d5a339bca00b /networking | |
parent | 872138de50b1c5bbf105b0243f5778fcb02b310b (diff) | |
download | busybox-0d5835a7674e8f36a5669e567be32d53dff401ac.zip busybox-0d5835a7674e8f36a5669e567be32d53dff401ac.tar.gz |
Apply patch from "Orion Poplawski" <OPoplawski@cqg.com> to make
hostname do "--file"
-Erik
Diffstat (limited to 'networking')
-rw-r--r-- | networking/hostname.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/networking/hostname.c b/networking/hostname.c index 16a28ca..44d529c 100644 --- a/networking/hostname.c +++ b/networking/hostname.c @@ -1,6 +1,6 @@ /* vi: set sw=4 ts=4: */ /* - * $Id: hostname.c,v 1.14 2000/09/27 02:43:35 kraai Exp $ + * $Id: hostname.c,v 1.15 2000/10/12 22:30:31 andersen Exp $ * Mini hostname implementation for busybox * * Copyright (C) 1999 by Randolph Chung <tausq@debian.org> @@ -89,6 +89,12 @@ int hostname_main(int argc, char **argv) } filename = *(++argv); break; + case '-': + if (strcmp(++(*argv), "file") || --argc ==0 ) { + usage(hostname_usage); + } + filename = *(++argv); + break; default: usage(hostname_usage); } |