diff --git a/thttpd-2.25b-getline.patch b/thttpd-2.25b-getline.patch new file mode 100644 index 0000000..2aaa0a5 --- /dev/null +++ b/thttpd-2.25b-getline.patch @@ -0,0 +1,20 @@ +--- extras/htpasswd.c ++++ extras/htpasswd.c +@@ -49,7 +49,7 @@ + while((line[y++] = line[x++])); + } + +-static int getline(char *s, int n, FILE *f) { ++static int my_getline(char *s, int n, FILE *f) { + register int i=0; + + while(1) { +@@ -189,7 +189,7 @@ + strncpy(user,argv[2],MAX_STRING_LEN); + user[MAX_STRING_LEN-1]='\0'; + found = 0; +- while(!(getline(line,MAX_STRING_LEN,f))) { ++ while(!(my_getline(line,MAX_STRING_LEN,f))) { + if(found || (line[0] == '#') || (!line[0])) { + putline(tfp,line); + continue; diff --git a/thttpd.changes b/thttpd.changes index 2d68b27..12d9a21 100644 --- a/thttpd.changes +++ b/thttpd.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Jun 8 00:41:37 CEST 2009 - ro@suse.de + +- rename getline to my_getline to avoid collision with function + from glibc + ------------------------------------------------------------------- Tue May 26 15:18:48 CEST 2009 - anicka@suse.cz diff --git a/thttpd.spec b/thttpd.spec index 7e01920..44c229a 100644 --- a/thttpd.spec +++ b/thttpd.spec @@ -24,7 +24,7 @@ Provides: http_daemon PreReq: %fillup_prereq %insserv_prereq permissions AutoReqProv: on Version: 2.25b -Release: 172 +Release: 173 Source: %{name}-%{version}.tar.bz2 Source1: %{name}-SuSE.tar.bz2 Patch0: %{name}-%{version}-configure.patch @@ -39,6 +39,7 @@ Patch8: %{name}-%{version}-overflow.diff Patch9: %{name}-%{version}-chown.diff Patch10: %{name}-%{version}-zerolen.patch Patch11: %{name}-%{version}-strcpy.patch +Patch12: thttpd-2.25b-getline.patch Url: http://www.acme.com/software/thttpd/ BuildRoot: %{_tmppath}/%{name}-%{version}-build Summary: Small and very simple webserver @@ -73,6 +74,7 @@ Authors: %patch9 %patch10 %patch11 +%patch12 %build # update server root path @@ -143,6 +145,9 @@ rm -rf "%{buildroot}" %config(noreplace) /etc/thttpd.conf %changelog +* Mon Jun 08 2009 ro@suse.de +- rename getline to my_getline to avoid collision with function + from glibc * Tue May 26 2009 anicka@suse.cz - add new branding (bnc#492693) * Mon Jun 11 2007 pcerny@suse.cz