FreeBSD Bugzilla – Attachment 72899 Details for
Bug 105832
[patch] make archivers/unzoo more FreeBSD 4.x friendly
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 2.49 KB, created by
Eugene Grosbein
on 2006-11-24 18:20:05 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
Eugene Grosbein
Created:
2006-11-24 18:20:05 UTC
Size:
2.49 KB
patch
obsolete
>diff -urN unzoo.orig/Makefile unzoo/Makefile >--- unzoo.orig/Makefile Sat Nov 25 00:46:18 2006 >+++ unzoo/Makefile Sat Nov 25 01:02:20 2006 >@@ -7,7 +7,7 @@ > > PORTNAME= unzoo > PORTVERSION= 4.4 >-PORTREVISION= 1 >+PORTREVISION= 2 > CATEGORIES= archivers > MASTER_SITES= ${MASTER_SITE_DEBIAN_POOL} > DISTNAME= ${PORTNAME}_${PORTVERSION}.orig >@@ -18,8 +18,6 @@ > > MAINTAINER= ehaupt@FreeBSD.org > COMMENT= A zoo archive extractor >- >-USE_GCC= 3.2+ > > EXTRA_DEFINES= -DSYS_IS_UNIX -DSYS_HAS_MKDIR > >diff -urN unzoo.orig/files/patch-unzoo.c unzoo/files/patch-unzoo.c >--- unzoo.orig/files/patch-unzoo.c Thu Jan 1 07:00:00 1970 >+++ unzoo/files/patch-unzoo.c Sat Nov 25 01:00:45 2006 >@@ -0,0 +1,48 @@ >+--- unzoo.c.orig Sat Nov 25 00:53:57 2006 >++++ unzoo.c Sat Nov 25 01:00:42 2006 >+@@ -2590,20 +2590,20 @@ >+ /* but only if the user did not request otherwise */ >+ >+ /* building the universal path of this member */ >++ int found_trav = 0; >+ char patu [sizeof(Entry.diru) + sizeof(Entry.namu) + 2]; >+ strcpy( patu, Entry.diru ); >+ if ( strlen(patu) && patu[strlen(patu)-1] != '/') strcat( patu, "/" ); >+ strcat( patu, (Entry.lnamu ? Entry.namu : Entry.nams) ); >+ >+- int found_trav = 0; >+ >+ if ( strstr( patu, "/../" )) { >+- found_trav = 1; >+ >+ /* remove "/../" from the path */ >+ char tmp [sizeof(patu)]; >+ char *p; >+ char *q; >++ found_trav = 1; >+ memset(tmp, 0, sizeof(tmp)); >+ q = patu; >+ >+@@ -2625,10 +2625,10 @@ >+ printf("unzoo: skipped \"/../\" path component(s) in '%s'\n", Entry.patl); >+ } >+ if ( *patu == '/' && !strlen( pre ) ) { >+- found_trav = 1; >+ >+ char *p = malloc(sizeof(patu)); >+ char *q = p; >++ found_trav = 1; >+ memset(p, 0, sizeof(patu)); >+ strcpy(p, patu); >+ while ( q[0] == '/' ) q++; >+@@ -2638,9 +2638,9 @@ >+ printf("unzoo: skipped root directory path component in '%s'\n", patl); >+ } >+ if ( !strncmp( patu, "../", 3 )) { >+- found_trav = 1; >+ >+ char tmp [sizeof(patu)]; >++ found_trav = 1; >+ memset(tmp, 0, sizeof(tmp)); >+ strcpy(tmp, patu + 3); >+ strcpy(patu, tmp);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 105832
: 72899