Репозитории ALT
Группа :: Система/Настройка/Сеть
Пакет: hostinfo
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
Патч: hostinfo-2.2-alt-fixes.patch
Скачать
Скачать
--- /dev/null 2005-01-05 23:15:16 +0300
+++ hostinfo-2.2/hostinfo.1.inc 2005-04-19 02:55:34 +0400
@@ -0,0 +1,2 @@
+[NAME]
+\fBhostinfo\fR \- utility for looking up hostnames and IP addresses.
--- hostinfo-2.2/hostinfo.c.orig 2000-07-20 15:34:40 +0400
+++ hostinfo-2.2/hostinfo.c 2005-04-19 03:06:19 +0400
@@ -22,6 +22,7 @@
#include <netdb.h>
#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
/* This is arbitrarily dependent on IPv4 to be right. */
@@ -47,10 +48,7 @@
static int print_only = 0;
static char *usage_info =
-"Usage:\n"
-" %s [-a] [-n] [-l] [-1] [-{x|o|d}] [-{X|O|D|N}] [-p] <host> [<host>...]\n"
-" %s --help\n"
-" %s --version\n"
+"Usage: %s [-a] [-n] [-l] [-1] [-{x|o|d}] [-{X|O|D|N}] [-p] <host> [<host>...]\n"
"\n"
"Find and print name, IP address(es), and aliases (if any) of each\n"
"specified host. By default, first try to interpret <host> as a\n"
@@ -131,7 +129,8 @@
;
static char *copyright_info =
-"by Jim Knoble <jmknoble@jmknoble.cx>\n"
+"Written by Jim Knoble <jmknoble@jmknoble.cx>\n"
+"\n"
"Copyright (C) 1998,1999,2000 Jim Knoble\n"
"\n"
"THIS SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n"
@@ -150,14 +149,14 @@
;
void print_help() {
- printf(usage_info, prog_name, prog_name, prog_name);
- exit(1);
+ printf(usage_info, prog_name, prog_name, prog_name, prog_name);
+ exit(0);
}
void print_version() {
printf("%s version %s (%s)\n", NAME, VERSION, DATE);
printf(copyright_info);
- exit(2);
+ exit(0);
}
int check_conflict2(char **argv, int argi1, int argi2) {