diff options
author | martin <martin@pkgsrc.org> | 2009-09-28 11:29:32 +0000 |
---|---|---|
committer | martin <martin@pkgsrc.org> | 2009-09-28 11:29:32 +0000 |
commit | 5b75156ec1db21e2e335094af519a2655dee18d1 (patch) | |
tree | 6a61d1c4f80ffd895474142c5ff70d0147aa703c /games/xsokoban | |
parent | 20d94fd5fdcdceda77e5cc8eda6c25b63523c179 (diff) | |
download | pkgsrc-5b75156ec1db21e2e335094af519a2655dee18d1.tar.gz |
Rename getline() to scoregetline() to avoid a conflict on NetBSD-current
Diffstat (limited to 'games/xsokoban')
-rw-r--r-- | games/xsokoban/distinfo | 4 | ||||
-rw-r--r-- | games/xsokoban/patches/patch-ah | 58 |
2 files changed, 58 insertions, 4 deletions
diff --git a/games/xsokoban/distinfo b/games/xsokoban/distinfo index 95e04884c85..6f08407090c 100644 --- a/games/xsokoban/distinfo +++ b/games/xsokoban/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.1.1.1 2009/04/08 16:31:56 drochner Exp $ +$NetBSD: distinfo,v 1.2 2009/09/28 11:29:32 martin Exp $ SHA1 (xsokoban-3.3c.tar.gz) = d5a829a8a507c60458093baa431e4fe9ff619aed RMD160 (xsokoban-3.3c.tar.gz) = 394cc9663982004f27135baad4e26c18c2c6817c @@ -10,4 +10,4 @@ SHA1 (patch-ad) = 2338d0e6afac7709abfe55eb57e809247d42b6f1 SHA1 (patch-ae) = 234e46167bf5b3786462488c99bf10de60736452 SHA1 (patch-af) = 43b4abe82c6cb7d51ad65e3eb1ef05fc345916a4 SHA1 (patch-ag) = 77a33b22e071637377e25636dd2df8ec45ac9d1e -SHA1 (patch-ah) = 1d8cb6cf6c5e57c8bb4a019e73eca9c56c21306f +SHA1 (patch-ah) = f8676279013c8f4be67bb4771fec3ed5b473a913 diff --git a/games/xsokoban/patches/patch-ah b/games/xsokoban/patches/patch-ah index cec20bb9652..c705c22dcbc 100644 --- a/games/xsokoban/patches/patch-ah +++ b/games/xsokoban/patches/patch-ah @@ -1,7 +1,7 @@ -$NetBSD: patch-ah,v 1.1.1.1 2009/04/08 16:31:56 drochner Exp $ +$NetBSD: patch-ah,v 1.2 2009/09/28 11:29:32 martin Exp $ --- score.c.orig 1996-08-27 21:23:58.000000000 +0200 -+++ score.c ++++ score.c 2009-09-28 13:15:32.000000000 +0200 @@ -633,10 +633,11 @@ static short WriteScore() char tempfile[MAXPATHLEN]; strcpy(tempfile, tempnm); @@ -17,3 +17,57 @@ $NetBSD: patch-ah,v 1.1.1.1 2009/04/08 16:31:56 drochner Exp $ scoreentries = htons(scoreentries); if (fwrite(SCORE_VERSION, 4, 1, scorefile) != 1) { +@@ -797,7 +798,7 @@ static void CopyEntry(short i1, short i2 + } + + /* Extract one line from "text". Return 0 if there is no line to extract. */ +-char *getline(char *text, char *linebuf, int bufsiz) ++char *scoregetline(char *text, char *linebuf, int bufsiz) + { + if (*text == 0) { + *linebuf = 0; +@@ -938,7 +939,7 @@ char *skip_past_header(char *text) + { + char line[256]; + do { +- text = getline(text, line, sizeof(line)); ++ text = scoregetline(text, line, sizeof(line)); + if (!text) return 0; + } while (0 != strcmp(line, "")); + return text; +@@ -982,7 +983,7 @@ static short ParseUserLevel(char *text, + char line[256]; + text = skip_past_header(text); + if (!text) return E_READSCORE; +- text = getline(text, line, sizeof(line)); ++ text = scoregetline(text, line, sizeof(line)); + if (!text) return E_READSCORE; + if (0 == strncmp(line, "Level: ", 7)) { + *lv = atoi(&line[7]); +@@ -999,7 +1000,7 @@ static void DeleteAllEntries() + } + + #define GRAB(tag, stmt) \ +- text = getline(text, line, sizeof(line)); \ ++ text = scoregetline(text, line, sizeof(line)); \ + if (!text) return E_READSCORE; \ + if (0 == strncmp(line, tag, strlen(tag))) { stmt; } \ + else return E_READSCORE; +@@ -1070,7 +1071,7 @@ static short ParseScoreText(char *text, + { + char line[256]; + do { +- text = getline(text, line, sizeof(line)); ++ text = scoregetline(text, line, sizeof(line)); + if (!text) return E_READSCORE; + } while (line[0] != '='); + scoreentries = 0; +@@ -1091,7 +1092,7 @@ static short ParseScoreLine(int i, char + int rank; + char rank_s[4]; + char line[256]; +- *text = getline(*text, line, sizeof(line)); ++ *text = scoregetline(*text, line, sizeof(line)); + if (!*text) return 0; + strncpy(rank_s, line, 4); + rank = atoi(rank_s); |