rpms/xpilot-ng/devel xpilot-ng-4.7.2-getline.patch, NONE, 1.1 xpilot-ng.spec, 1.18, 1.19

Hans de Goede jwrdegoede at fedoraproject.org
Fri Jan 15 12:59:58 UTC 2010


Author: jwrdegoede

Update of /cvs/pkgs/rpms/xpilot-ng/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv22155

Modified Files:
	xpilot-ng.spec 
Added Files:
	xpilot-ng-4.7.2-getline.patch 
Log Message:
* Fri Jan 15 2010 Hans de Goede <hdegoede at redhat.com> - 4.7.2-18
- Fix FTBFS (#511717)


xpilot-ng-4.7.2-getline.patch:
 textinterface.c |   18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

--- NEW FILE xpilot-ng-4.7.2-getline.patch ---
diff -up xpilot-ng-4.7.2/src/client/textinterface.c~ xpilot-ng-4.7.2/src/client/textinterface.c
--- xpilot-ng-4.7.2/src/client/textinterface.c~	2005-09-02 19:06:20.000000000 +0200
+++ xpilot-ng-4.7.2/src/client/textinterface.c	2010-01-15 12:34:07.000000000 +0100
@@ -37,7 +37,7 @@ extern int		dgram_one_socket;	/* from da
 /*
  * just like fgets() but strips newlines like gets().
  */
-static char* getline(char* buf, int len, FILE* stream)
+static char* xp_getline(char* buf, int len, FILE* stream)
 {
     char		*nl;
 
@@ -251,7 +251,7 @@ static bool Process_commands(sockbuf_t *
 	else if (!auto_connect) {
 	    printf("*** Server on %s. Enter command> ", conpar->server_name);
 
-	    getline(linebuf, MAX_LINE, stdin);
+	    xp_getline(linebuf, MAX_LINE, stdin);
 	    if (feof(stdin)) {
 		puts("");
 		c = 'Q';
@@ -338,7 +338,7 @@ static bool Process_commands(sockbuf_t *
 	    case 'K':
 		printf("Enter name of victim: ");
 		fflush(stdout);
-		if (!getline(linebuf, MAX_LINE, stdin)) {
+		if (!xp_getline(linebuf, MAX_LINE, stdin)) {
 		    printf("Nothing changed.\n");
 		    continue;
 		}
@@ -349,7 +349,7 @@ static bool Process_commands(sockbuf_t *
 	    case 'M':				/* Send a message to server. */
 		printf("Enter message: ");
 		fflush(stdout);
-		if (!getline(linebuf, MAX_LINE, stdin) || !linebuf[0]) {
+		if (!xp_getline(linebuf, MAX_LINE, stdin) || !linebuf[0]) {
 		    printf("No message sent.\n");
 		    continue;
 		}
@@ -364,7 +364,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, stdin);
+		    xp_getline(linebuf, MAX_LINE, stdin);
 		    /*
 		     * No argument = cancel shutdown = arg_int=0
 		     */
@@ -375,7 +375,7 @@ static bool Process_commands(sockbuf_t *
 			    delay = 1;
 
 		    printf("Enter reason: ");
-		    getline(linebuf, MAX_LINE, stdin);
+		    xp_getline(linebuf, MAX_LINE, stdin);
 		} else {
 		    strlcpy(linebuf, shutdown_reason, sizeof(linebuf));
 		    delay = 60;
@@ -388,7 +388,7 @@ static bool Process_commands(sockbuf_t *
 	    case 'O':				/* Tune an option. */
 		printf("Enter option: ");
 		fflush(stdout);
-		if (!getline(linebuf, MAX_LINE, stdin)
+		if (!xp_getline(linebuf, MAX_LINE, stdin)
 		    || (len=strlen(linebuf)) == 0) {
 		    printf("Nothing changed.\n");
 		    continue;
@@ -396,7 +396,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-len, stdin)
+		if (!xp_getline(&linebuf[len], MAX_LINE-len, stdin)
 		    || linebuf[len] == '\0') {
 		    printf("Nothing changed.\n");
 		    continue;
@@ -450,7 +450,7 @@ static bool Process_commands(sockbuf_t *
 	    case 'T':				/* Set team. */
 		printf("Enter team: ");
 		fflush(stdout);
-		if (!getline(linebuf, MAX_LINE, stdin)
+		if (!xp_getline(linebuf, MAX_LINE, stdin)
 		    || (len = strlen(linebuf)) == 0)
 		    printf("Nothing changed.\n");
 		else {


Index: xpilot-ng.spec
===================================================================
RCS file: /cvs/pkgs/rpms/xpilot-ng/devel/xpilot-ng.spec,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -p -r1.18 -r1.19
--- xpilot-ng.spec	27 Jul 2009 08:41:45 -0000	1.18
+++ xpilot-ng.spec	15 Jan 2010 12:59:58 -0000	1.19
@@ -7,7 +7,7 @@
 
 Name:           xpilot-ng
 Version:        4.7.2
-Release:        17%{?dist}
+Release:        18%{?dist}
 Summary:        Multiplayer space arcade game
 
 Group:          Amusements/Games
@@ -28,6 +28,7 @@ Source11:       logwatch.script.xpilot
 Source12:       logwatch.serviceconf.xpilot
 Source13:       logwatch.shared.applyxpilotdate
 Patch0:         xpilot-ng-4.7.2-scoreassert.patch
+Patch1:         xpilot-ng-4.7.2-getline.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  desktop-file-utils
@@ -79,6 +80,7 @@ logwatch scripts for the Xpilot game ser
 %prep
 %setup -q
 %patch0
+%patch1 -p1
 pushd doc/man
 iconv --from=ISO-8859-1 --to=UTF-8 xpilot-ng-server.man > xpilot-ng-server.man.new
 mv xpilot-ng-server.man.new xpilot-ng-server.man
@@ -267,6 +269,9 @@ rm -rf $RPM_BUILD_ROOT
 %{logwatch_scripts}/shared/applyxpilotdate
 
 %changelog
+* Fri Jan 15 2010 Hans de Goede <hdegoede at redhat.com> - 4.7.2-18
+- Fix FTBFS (#511717)
+
 * Mon Jul 27 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 4.7.2-17
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
 



More information about the scm-commits mailing list