Apply patch from "Orion Poplawski" <OPoplawski@cqg.com> to make
hostname do "--file" -Erik
This commit is contained in:
parent
872138de50
commit
0d5835a767
@ -458,7 +458,7 @@ const char hostname_usage[] =
|
|||||||
|
|
||||||
"\t-i\t\tAddresses for the hostname\n"
|
"\t-i\t\tAddresses for the hostname\n"
|
||||||
"\t-d\t\tDNS domain name\n"
|
"\t-d\t\tDNS domain name\n"
|
||||||
"\t-F FILE\t\tUse the contents of FILE to specify the hostname\n"
|
"\t-F, --file FILE\tUse the contents of FILE to specify the hostname\n"
|
||||||
#endif
|
#endif
|
||||||
;
|
;
|
||||||
#endif
|
#endif
|
||||||
|
@ -827,7 +827,7 @@ Options:
|
|||||||
-s Short
|
-s Short
|
||||||
-i Addresses for the hostname
|
-i Addresses for the hostname
|
||||||
-d DNS domain name
|
-d DNS domain name
|
||||||
-F FILE Use the contents of FILE to specify the hostname
|
-F, --file FILE Use the contents of FILE to specify the hostname
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
@ -2261,4 +2261,4 @@ Enrique Zanardi <ezanardi@ull.es>
|
|||||||
|
|
||||||
=cut
|
=cut
|
||||||
|
|
||||||
# $Id: busybox.pod,v 1.74 2000/09/26 22:20:06 andersen Exp $
|
# $Id: busybox.pod,v 1.75 2000/10/12 22:30:31 andersen Exp $
|
||||||
|
@ -1397,10 +1397,10 @@
|
|||||||
|
|
||||||
<para>
|
<para>
|
||||||
<screen>
|
<screen>
|
||||||
-s Short
|
-s Short
|
||||||
-i Addresses for the hostname
|
-i Addresses for the hostname
|
||||||
-d DNS domain name
|
-d DNS domain name
|
||||||
-F FILE Use the contents of FILE to specify the hostname
|
-F, --file FILE Use the contents of FILE to specify the hostname
|
||||||
</screen>
|
</screen>
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* vi: set sw=4 ts=4: */
|
/* 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
|
* Mini hostname implementation for busybox
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 by Randolph Chung <tausq@debian.org>
|
* Copyright (C) 1999 by Randolph Chung <tausq@debian.org>
|
||||||
@ -89,6 +89,12 @@ int hostname_main(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
filename = *(++argv);
|
filename = *(++argv);
|
||||||
break;
|
break;
|
||||||
|
case '-':
|
||||||
|
if (strcmp(++(*argv), "file") || --argc ==0 ) {
|
||||||
|
usage(hostname_usage);
|
||||||
|
}
|
||||||
|
filename = *(++argv);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
usage(hostname_usage);
|
usage(hostname_usage);
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* vi: set sw=4 ts=4: */
|
/* 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
|
* Mini hostname implementation for busybox
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 by Randolph Chung <tausq@debian.org>
|
* Copyright (C) 1999 by Randolph Chung <tausq@debian.org>
|
||||||
@ -89,6 +89,12 @@ int hostname_main(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
filename = *(++argv);
|
filename = *(++argv);
|
||||||
break;
|
break;
|
||||||
|
case '-':
|
||||||
|
if (strcmp(++(*argv), "file") || --argc ==0 ) {
|
||||||
|
usage(hostname_usage);
|
||||||
|
}
|
||||||
|
filename = *(++argv);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
usage(hostname_usage);
|
usage(hostname_usage);
|
||||||
}
|
}
|
||||||
|
2
usage.c
2
usage.c
@ -458,7 +458,7 @@ const char hostname_usage[] =
|
|||||||
|
|
||||||
"\t-i\t\tAddresses for the hostname\n"
|
"\t-i\t\tAddresses for the hostname\n"
|
||||||
"\t-d\t\tDNS domain name\n"
|
"\t-d\t\tDNS domain name\n"
|
||||||
"\t-F FILE\t\tUse the contents of FILE to specify the hostname\n"
|
"\t-F, --file FILE\tUse the contents of FILE to specify the hostname\n"
|
||||||
#endif
|
#endif
|
||||||
;
|
;
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user