rpms/bsd-games/F-12 bsd-games-2.17-backgammonsize.patch, NONE, 1.1 bsd-games.spec, 1.23, 1.24

Michael Thomas wart at fedoraproject.org
Mon Apr 19 03:53:32 UTC 2010


Author: wart

Update of /cvs/pkgs/rpms/bsd-games/F-12
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv23146

Modified Files:
	bsd-games.spec 
Added Files:
	bsd-games-2.17-backgammonsize.patch 
Log Message:
Add patch to fix core dump in backgammon when screen is < 24 lines tall (BZ #580749)



bsd-games-2.17-backgammonsize.patch:
 fancy.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- NEW FILE bsd-games-2.17-backgammonsize.patch ---
--- backgammon/common_source/fancy.c.orig	2010-04-18 16:59:55.000000000 -0700
+++ backgammon/common_source/fancy.c	2010-04-18 17:27:47.000000000 -0700
@@ -575,7 +575,7 @@
 	}
 	curr = curc = 0;	/* fix position markers */
 	realr = realc = -1;
-	for (i = 0; i < 24; i++)/* clear line counts */
+	for (i = 0; i < LI; i++)/* clear line counts */
 		linect[i] = -1;
 	buffnum = -1;		/* ignore leftover buffer contents */
 	tputs(CL, CO, addbuf);	/* put CL in buffer */
@@ -726,9 +726,9 @@
 		lUP = strlen(UP);
 	if (ND)
 		lND = strlen(ND);
+	linect = (int *) calloc(LI + 1, sizeof(int));
 	if (LI < 24 || CO < 72 || !(CL && UP && ND))
 		return (0);
-	linect = (int *) calloc(LI + 1, sizeof(int));
 	if (linect == NULL) {
 		write(2, "\r\nOut of memory!\r\n", 18);
 		getout(0);


Index: bsd-games.spec
===================================================================
RCS file: /cvs/pkgs/rpms/bsd-games/F-12/bsd-games.spec,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -p -r1.23 -r1.24
--- bsd-games.spec	10 Jan 2010 23:16:43 -0000	1.23
+++ bsd-games.spec	19 Apr 2010 03:53:32 -0000	1.24
@@ -4,7 +4,7 @@
 Summary: Collection of text-based games
 Name: bsd-games
 Version: 2.17
-Release: 29%{?dist}
+Release: 30%{?dist}
 License: BSD and BSD with advertising
 Group: Amusements/Games
 URL: ftp://metalab.unc.edu/pub/Linux/games/
@@ -33,6 +33,7 @@ Patch12: bsd-games-2.17-tetris-rename.pa
 Patch13: bsd-games-2.17-gcc43.patch
 Patch14: bsd-games-2.17-bogglewords.patch
 Patch15: bsd-games-2.17-wtfupdate.patch
+Patch16: bsd-games-2.17-backgammonsize.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires: ncurses-devel words flex bison
 Requires(Pre): /usr/sbin/groupadd
@@ -63,6 +64,7 @@ install -p -m 755 %{SOURCE1} .
 %patch13 -p1 -b .gcc43
 %patch14 -p0 -b .wordlimit
 %patch15 -p0 -b .wtfupdate
+%patch16 -p0 -b .backgammonsize
 
 %build
 # We include a templatized configuration settings file to set
@@ -187,6 +189,10 @@ rm -rf $RPM_BUILD_ROOT
 %doc AUTHORS COPYING ChangeLog ChangeLog.0 THANKS YEAR2000 README.hunt trek/USD.doc/trek.me
 
 %changelog
+* Sun Apr 18 2010 Wart <wart at kobold.org> 2.17-30
+- Add patch to fix core dump in backgammon when screen is < 24 lines
+  tall (BZ #580749)
+
 * Tue Oct 20 2009 Wart <wart at kobold.org> 2.17-29
 - Updated acronym databases (BZ #529921)
 - Allow more words in a boggle game (BZ #500187)



More information about the scm-commits mailing list