diff options
Diffstat (limited to 'games')
-rw-r--r-- | games/xpilot/distinfo | 3 | ||||
-rw-r--r-- | games/xpilot/patches/patch-af | 94 |
2 files changed, 96 insertions, 1 deletions
diff --git a/games/xpilot/distinfo b/games/xpilot/distinfo index 3a8512a4cd0..f01a8ef2cf1 100644 --- a/games/xpilot/distinfo +++ b/games/xpilot/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.9 2010/01/07 15:22:49 is Exp $ +$NetBSD: distinfo,v 1.10 2010/04/29 00:48:48 dholland Exp $ SHA1 (xpilot-4.5.4.tar.gz) = d295977be8c27c3b9aecf8e69061a451bf8d7e4b RMD160 (xpilot-4.5.4.tar.gz) = db8e62fbfa7a7ba19abeb41da651ae4b0298bbc2 @@ -8,3 +8,4 @@ SHA1 (patch-ab) = 26e80e4ef932bc2f5ebcff19b2d41f83641be83c SHA1 (patch-ac) = 949ea447de5bd653a849ec16fc044c803615f6c6 SHA1 (patch-ad) = 88ffc97307afe633a626027d6699bb08b3c0827e SHA1 (patch-ae) = a459b61013bddc3b214811568cf660131221b7da +SHA1 (patch-af) = aa769aa13db20d9905dd9721283d1dd30491f1ea diff --git a/games/xpilot/patches/patch-af b/games/xpilot/patches/patch-af new file mode 100644 index 00000000000..ff22a3b91fa --- /dev/null +++ b/games/xpilot/patches/patch-af @@ -0,0 +1,94 @@ +$NetBSD: patch-af,v 1.1 2010/04/29 00:48:48 dholland Exp $ + +--- src/client/textinterface.c~ 2001-07-31 17:35:33.000000000 +0000 ++++ src/client/textinterface.c +@@ -75,7 +75,7 @@ extern char hostname[]; /* my local ho + /* + * just like fgets() but strips newlines like gets(). + */ +-static char* getline(char* buf, int len, FILE* stream) ++static char* get_line(char* buf, int len, FILE* stream) + { + char *nl; + +@@ -305,7 +305,7 @@ static bool Process_commands(sockbuf_t * + else if (!auto_connect) { + printf("*** Server on %s. Enter command> ", conpar->server_name); + +- getline(linebuf, MAX_LINE-1, stdin); ++ get_line(linebuf, MAX_LINE-1, stdin); + if (feof(stdin)) { + puts(""); + c = 'Q'; +@@ -385,7 +385,7 @@ static bool Process_commands(sockbuf_t * + case 'K': + printf("Enter name of victim: "); + fflush(stdout); +- if (!getline(linebuf, MAX_LINE-1, stdin)) { ++ if (!get_line(linebuf, MAX_LINE-1, stdin)) { + printf("Nothing changed.\n"); + continue; + } +@@ -396,7 +396,7 @@ static bool Process_commands(sockbuf_t * + case 'R': + printf("Enter maximum number of robots: "); + fflush(stdout); +- if (!getline(linebuf, MAX_LINE-1, stdin)) { ++ if (!get_line(linebuf, MAX_LINE-1, stdin)) { + printf("Nothing changed.\n"); + continue; + } +@@ -410,7 +410,7 @@ static bool Process_commands(sockbuf_t * + case 'M': /* Send a message to server. */ + printf("Enter message: "); + fflush(stdout); +- if (!getline(linebuf, MAX_LINE-1, stdin) || !linebuf[0]) { ++ if (!get_line(linebuf, MAX_LINE-1, stdin) || !linebuf[0]) { + printf("No message sent.\n"); + continue; + } +@@ -425,7 +425,7 @@ static bool Process_commands(sockbuf_t * + case 'D': /* Shutdown */ + if (!auto_shutdown) { + printf("Enter delay in seconds or return for cancel: "); +- getline(linebuf, MAX_LINE-1, stdin); ++ get_line(linebuf, MAX_LINE-1, stdin); + /* + * No argument = cancel shutdown = arg_int=0 + */ +@@ -436,7 +436,7 @@ static bool Process_commands(sockbuf_t * + delay = 1; + + printf("Enter reason: "); +- getline(linebuf, MAX_LINE-1, stdin); ++ get_line(linebuf, MAX_LINE-1, stdin); + } else { + strlcpy(linebuf, shutdown_reason, sizeof(linebuf)); + delay = 60; +@@ -448,7 +448,7 @@ static bool Process_commands(sockbuf_t * + case 'O': /* Tune an option. */ + printf("Enter option: "); + fflush(stdout); +- if (!getline(linebuf, MAX_LINE-1, stdin) ++ if (!get_line(linebuf, MAX_LINE-1, stdin) + || (len=strlen(linebuf)) == 0) { + printf("Nothing changed.\n"); + continue; +@@ -456,7 +456,7 @@ static bool Process_commands(sockbuf_t * + printf("Enter new value for %s: ", linebuf); + fflush(stdout); + strcat(linebuf, ":"); len++; +- if (!getline(&linebuf[len], MAX_LINE-1-len, stdin) ++ if (!get_line(&linebuf[len], MAX_LINE-1-len, stdin) + || linebuf[len] == '\0') { + printf("Nothing changed.\n"); + continue; +@@ -516,7 +516,7 @@ static bool Process_commands(sockbuf_t * + case 'T': /* Set team. */ + printf("Enter team: "); + fflush(stdout); +- if (!getline(linebuf, MAX_LINE-1, stdin) ++ if (!get_line(linebuf, MAX_LINE-1, stdin) + || (len = strlen(linebuf)) == 0) { + printf("Nothing changed.\n"); + } |