FreeBSD Bugzilla – Attachment 185526 Details for
Bug 221589
archivers/arj: fix build on armv6, fix multiple vulnerabilities and other improvements
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
patch
archivers_arj.diff (text/plain), 27.62 KB, created by
Mikael Urankar
on 2017-08-17 14:20:27 UTC
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Mikael Urankar
Created:
2017-08-17 14:20:27 UTC
Size:
27.62 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 448024) >+++ Makefile (working copy) >@@ -3,7 +3,7 @@ > > PORTNAME= arj > PORTVERSION= 3.10.22 >-PORTREVISION= 4 >+PORTREVISION= 5 > CATEGORIES= archivers > MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/2.78_3.10%20build%2022 > >@@ -21,7 +21,6 @@ > MAKE_ARGS= LOCALE="${LANGUAGE}" > ALL_TARGET= prepare all > STRIP= # empty >-MAKE_JOBS_UNSAFE= yes > > CFLAGS+= -fPIC > LANGUAGE?= en >Index: files/patch-arj__arcv.c >=================================================================== >--- files/patch-arj__arcv.c (revision 448024) >+++ files/patch-arj__arcv.c (working copy) >@@ -58,3 +58,49 @@ > } > > /* Calculates and stores the basic header size */ >+@@ -913,13 +913,13 @@ int supply_comment(char *cmtname, char *name) >+ else >+ { >+ strcat(tmp_comment, tmp_cmtline); >+- strcat(tmp_comment, lf); >++ strcat(tmp_comment, "\n"); >+ } >+ } >+ else >+ { >+ strcat(tmp_comment, tmp_cmtline); >+- strcat(tmp_comment, lf); >++ strcat(tmp_comment, "\n"); >+ } >+ } >+ } >+@@ -1846,7 +1846,7 @@ int pack_file(int is_update, int is_replace) >+ raw_eh=eh_lookup(eh, UXSPECIAL_ID)->raw; >+ uxspecial_stats(raw_eh, UXSTATS_SHORT); >+ } >+- msg_cprintf(0, lf); >++ msg_cprintf(0, "\n"); >+ } >+ if(err_id==0&&user_wants_fail) >+ { >+@@ -2523,9 +2523,9 @@ int unpack_validation() >+ { >+ msg_cprintf(0, (FMSG *)strform, misc_buf); >+ if(search_mode==SEARCH_DEFAULT) >+- msg_cprintf(0, (FMSG *)lf); >++ msg_cprintf(0, "\n"); >+ if(search_mode==SEARCH_BRIEF) >+- msg_cprintf(0, (FMSG *)cr); >++ msg_cprintf(0, "\r"); >+ } >+ for(pattern=0; pattern<SEARCH_STR_MAX; search_occurences[pattern++]=0); >+ reserve_size=0; >+@@ -3652,7 +3652,7 @@ void archive_cleanup() >+ { >+ if(msg_fprintf(idxstream, M_TESTING, archive_name)<0) >+ error(M_DISK_FULL); >+- if(fprintf(idxstream, lf)<0) >++ if(fprintf(idxstream, "\n")<0) >+ error(M_DISK_FULL); >+ } >+ cmd_verb=ARJ_CMD_TEST; >Index: files/patch-arj__proc.c >=================================================================== >--- files/patch-arj__proc.c (revision 448024) >+++ files/patch-arj__proc.c (working copy) >@@ -9,7 +9,7 @@ > { > unsigned long pvol; > unsigned int arjsec_overhead; >-@@ -605,7 +605,7 @@ unsigned long get_volfree(unsigned int i >+@@ -605,7 +605,7 @@ unsigned long get_volfree(unsigned int increment) > remain=volume_limit-ftell(aostream)-pvol-(long)arjsec_overhead- > (long)out_bytes-(long)cpos-(long)ext_voldata- > MULTIVOLUME_RESERVE-t_volume_offset; >@@ -36,8 +36,12 @@ > tsptr++; > } > } >-@@ -2901,9 +2901,9 @@ char *ltrim(char *str) >- #if defined(WORDS_BIGENDIAN)&&!defined(ARJDISP)&&!defined(REGISTER) >+@@ -2898,12 +2898,12 @@ char *ltrim(char *str) >+ } >+ #endif >+ >+-#if defined(WORDS_BIGENDIAN)&&!defined(ARJDISP)&&!defined(REGISTER) >++#if (defined(WORDS_BIGENDIAN) || defined(ALIGN_POINTERS)) && !defined(ARJDISP) && !defined(REGISTER) > /* Model-independent routine to get 2 bytes from far RAM */ > > -unsigned int mget_word(char FAR *p) >@@ -69,7 +73,7 @@ > { > mput_byte(w&0xFF, p); > mput_byte(w>>8 , p+1); >-@@ -2931,7 +2931,7 @@ void mput_word(unsigned int w, char FAR >+@@ -2931,7 +2931,7 @@ void mput_word(unsigned int w, char FAR *p) > > /* Model-independent routine to store 4 bytes in far RAM */ > >Index: files/patch-arj__proc.h >=================================================================== >--- files/patch-arj__proc.h (revision 448024) >+++ files/patch-arj__proc.h (working copy) >@@ -10,13 +10,14 @@ > > -#define mget_byte(p) (*(unsigned char FAR *)(p)&0xFF) > -#define mput_byte(c, p) *(unsigned char FAR *)(p)=(unsigned char)(c) >-+#define mget_byte(p) (*(uint8_t FAR *)(p)&0xFF) >-+#define mput_byte(c, p) *(uint8_t FAR *)(p)=(uint8_t)(c) >- #ifndef WORDS_BIGENDIAN >+-#ifndef WORDS_BIGENDIAN > -#define mget_word(p) (*(unsigned short *)(p)&0xFFFF) > -#define mput_word(w,p) (*(unsigned short *)(p)=(unsigned short)(w)) > -#define mget_dword(p) (*(unsigned long *)(p)) > -#define mput_dword(w,p) (*(unsigned long *)(p)=(unsigned long)(w)) >++#define mget_byte(p) (*(uint8_t FAR *)(p)&0xFF) >++#define mput_byte(c, p) *(uint8_t FAR *)(p)=(uint8_t)(c) >++#if !defined(ALIGN_POINTERS) && !defined(WORDS_BIGENDIAN) > +#define mget_word(p) (*(uint16_t *)(p)&0xFFFF) > +#define mput_word(w,p) (*(uint16_t *)(p)=(uint16_t)(w)) > +#define mget_dword(p) (*(uint32_t *)(p)) >@@ -33,14 +34,16 @@ > unsigned int check_multivolume(unsigned int increment); > void store(); > void hollow_encode(); >-@@ -61,10 +63,10 @@ void unpack_mem(struct mempack *mempack) >+@@ -60,11 +62,11 @@ void pack_mem(struct mempack *mempack); >+ void unpack_mem(struct mempack *mempack); > void strip_lf(char *str); > char *ltrim(char *str); >- #ifdef WORDS_BIGENDIAN >+-#ifdef WORDS_BIGENDIAN > -unsigned int mget_word(char FAR *p); > -unsigned long mget_dword(char FAR *p); > -void mput_word(unsigned int w, char FAR *p); > -void mput_dword(unsigned long d, char FAR *p); >++#if defined(ALIGN_POINTERS) || defined(WORDS_BIGENDIAN) > +uint16_t mget_word(char FAR *p); > +uint32_t mget_dword(char FAR *p); > +void mput_word(uint16_t w, char FAR *p); >Index: files/patch-arj__user.c >=================================================================== >--- files/patch-arj__user.c (nonexistent) >+++ files/patch-arj__user.c (working copy) >@@ -0,0 +1,38 @@ >+--- arj_user.c.orig 2004-06-18 16:19:36 UTC >++++ arj_user.c >+@@ -1059,7 +1059,7 @@ static void finish_processing(int cmd) >+ if(recover_file(tmp_archive_name, nullstr, tmp_tmp_filename, protected, eof_pos)) >+ { >+ msg_cprintf(H_HL, M_CANT_FIND_DAMAGE, archive_name); >+- printf(lf); >++ printf("\n"); >+ } >+ else >+ { >+@@ -1294,7 +1294,7 @@ static void finish_processing(int cmd) >+ if(recover_file(archive_name, nullstr, nullstr, protected, eof_pos)) >+ { >+ msg_cprintf(H_HL, M_CANT_FIND_DAMAGE, archive_name); >+- printf(lf); >++ printf("\n"); >+ } >+ else >+ { >+@@ -1327,7 +1327,7 @@ static void finish_processing(int cmd) >+ msg_cprintf(0, M_CHAPTERS_ON); >+ else if(chapter_mode==CHAP_REMOVE) >+ msg_cprintf(0, M_CHAPTERS_OFF); >+- msg_cprintf(0, strform, lf); >++ msg_cprintf(0, strform, "\n"); >+ } >+ if(cmd==ARJ_CMD_COPY&&protfile_option&&!arjprot_tail) >+ msg_cprintf(0, M_ARJPROT_DISABLED); >+@@ -2303,7 +2303,7 @@ void process_archive() >+ timestamp_to_str(timetext, &ftime_stamp); >+ msg_cprintf(H_HL|H_NFMT, M_ARCHIVE_CREATED, timetext); >+ if(show_ansi_comments) >+- printf(cmt_ptr); >++ fputs(cmt_ptr, stdout); >+ else >+ display_comment(cmt_ptr); >+ /* The sfx_setup() occurs here */ > >Property changes on: files/patch-arj__user.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-arjdisp.c >=================================================================== >--- files/patch-arjdisp.c (nonexistent) >+++ files/patch-arjdisp.c (working copy) >@@ -0,0 +1,133 @@ >+--- arjdisp.c.orig 2003-06-22 11:12:28 UTC >++++ arjdisp.c >+@@ -20,8 +20,6 @@ static long bytes; >+ static long compsize; >+ static char cmd_verb; >+ static char msg_lf[]="\n"; >+-char strform[]="%s"; /* Export it for scrnio.c, too >+- (a byte saved is a byte gained) */ >+ >+ /* Pseudographical controls */ >+ >+@@ -54,19 +52,19 @@ static void show_init_scrn() >+ textcolor(7); >+ clrscr(); >+ gotoxy(2, 2); >+- scrprintf(win_top); >++ fputs(win_top, stdout); >+ for(i=3; i<24; i++) >+ { >+- gotoxy(2, i); scrprintf(win_border); >+- gotoxy(79, i); scrprintf(win_border); >++ gotoxy(2, i); fputs(win_border, stdout); >++ gotoxy(79, i); fputs(win_border, stdout); >+ } >+- gotoxy(2, 24); scrprintf(win_bottom); >++ gotoxy(2, 24); fputs(win_bottom, stdout); >+ gotoxy(10, 5); >+- scrprintf(M_ARJDISP_COPYRIGHT); >++ fputs(M_ARJDISP_COPYRIGHT, stdout); >+ gotoxy(10, 6); >+- scrprintf(M_ARJDISP_DISTRIBUTION); >++ fputs(M_ARJDISP_DISTRIBUTION, stdout); >+ gotoxy(10, 7); >+- scrprintf(M_ARJDISP_LICENSE); >++ fputs(M_ARJDISP_LICENSE, stdout); >+ gotoxy(16, 10); >+ scrprintf(M_PROCESSING_ARCHIVE, archive_name); >+ t=strtok(M_ARJDISP_INFO, msg_lf); >+@@ -74,11 +72,11 @@ static void show_init_scrn() >+ while(t!=NULL&&i<=23) >+ { >+ gotoxy(10, i++); >+- scrprintf(strform, t); >++ scrprintf("%s", t); >+ t=strtok(NULL, msg_lf); >+ } >+ gotoxy(16, 20); >+- scrprintf(M_PRESS_ANY_KEY); >++ fputs(M_PRESS_ANY_KEY, stdout); >+ uni_getch(); >+ gotoxy(1, 24); >+ } >+@@ -96,19 +94,19 @@ static void show_proc_scrn() >+ { >+ clrscr(); >+ gotoxy(2, 2); >+- scrprintf(win_top); >++ fputs(win_top, stdout); >+ for(i=3; i<24; i++) >+ { >+- gotoxy(2, i); scrprintf(win_border); >+- gotoxy(79, i); scrprintf(win_border); >++ gotoxy(2, i); fputs(win_border, stdout); >++ gotoxy(79, i); fputs(win_border, stdout); >+ } >+- gotoxy(2, 24); scrprintf(win_bottom); >++ gotoxy(2, 24); fputs(win_bottom, stdout); >+ gotoxy(10, 5); >+- scrprintf(M_ARJDISP_COPYRIGHT); >++ fputs(M_ARJDISP_COPYRIGHT, stdout); >+ gotoxy(10, 6); >+- scrprintf(M_ARJDISP_DISTRIBUTION); >++ fputs(M_ARJDISP_DISTRIBUTION, stdout); >+ gotoxy(10, 7); >+- scrprintf(M_ARJDISP_LICENSE); >++ fputs(M_ARJDISP_LICENSE, stdout); >+ gotoxy(16, 10); >+ scrprintf(M_PROCESSING_ARCHIVE, archive_name); >+ gotoxy(16, 12); >+@@ -132,13 +130,13 @@ static void show_proc_scrn() >+ break; >+ } >+ gotoxy(15, 14); >+- scrprintf(ind_top); >++ fputs(ind_top, stdout); >+ gotoxy(15, 15); >+- scrprintf(ind_middle); >++ fputs(ind_middle, stdout); >+ gotoxy(15, 16); >+- scrprintf(ind_bottom); >++ fputs(ind_bottom, stdout); >+ gotoxy(16, 18); >+- scrprintf(M_ARJDISP_CTR_START); >++ fputs(M_ARJDISP_CTR_START, stdout); >+ } >+ else >+ { >+@@ -146,7 +144,7 @@ static void show_proc_scrn() >+ gotoxy(16, 15); >+ memset(progress, indo, i); >+ progress[i]='\0'; >+- scrprintf(progress); >++ fputs(progress, stdout); >+ gotoxy(16, 18); >+ scrprintf(M_ARJDISP_CTR, calc_percentage(bytes, uncompsize)/10); >+ } >+@@ -165,19 +163,19 @@ static void show_ending_scrn() >+ textcolor(7); >+ clrscr(); >+ gotoxy(2, 2); >+- scrprintf(win_top); >++ fputs(win_top, stdout); >+ for(i=3; i<24; i++) >+ { >+- gotoxy(2, i); scrprintf(win_border); >+- gotoxy(79, i); scrprintf(win_border); >++ gotoxy(2, i); fputs(win_border, stdout); >++ gotoxy(79, i); fputs(win_border, stdout); >+ } >+- gotoxy(2, 24); scrprintf(win_bottom); >++ gotoxy(2, 24); fputs(win_bottom, stdout); >+ gotoxy(10, 5); >+- scrprintf(M_ARJDISP_COPYRIGHT); >++ fputs(M_ARJDISP_COPYRIGHT, stdout); >+ gotoxy(10, 6); >+- scrprintf(M_ARJDISP_DISTRIBUTION); >++ fputs(M_ARJDISP_DISTRIBUTION, stdout); >+ gotoxy(10, 7); >+- scrprintf(M_ARJDISP_LICENSE); >++ fputs(M_ARJDISP_LICENSE, stdout); >+ gotoxy(16, 10); >+ scrprintf(M_FINISHED_PROCESSING, archive_name); >+ gotoxy(1, 24); > >Property changes on: files/patch-arjdisp.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-arjsfx.c >=================================================================== >--- files/patch-arjsfx.c (nonexistent) >+++ files/patch-arjsfx.c (working copy) >@@ -0,0 +1,11 @@ >+--- arjsfx.c.orig 2005-06-21 19:53:14 UTC >++++ arjsfx.c >+@@ -214,7 +214,7 @@ static void final_cleanup(void) >+ freopen(dev_con, m_w, stdout); >+ #if SFX_LEVEL>=ARJSFXV >+ if(ferror(stdout)) >+- msg_fprintf(stderr, M_DISK_FULL); >++ msg_fprintf(stderr, "Can't write file. Disk full?"); >+ if(debug_enabled&&strchr(debug_opt, 't')!=NULL) >+ { >+ ticks=get_ticks()-ticks; > >Property changes on: files/patch-arjsfx.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-arjtypes.c >=================================================================== >--- files/patch-arjtypes.c (nonexistent) >+++ files/patch-arjtypes.c (working copy) >@@ -0,0 +1,15 @@ >+--- arjtypes.c.orig 2017-07-31 18:54:59 UTC >++++ arjtypes.c >+@@ -138,8 +138,11 @@ static int isleapyear(int year) >+ static unsigned long ts_unix2dos(const long ts) >+ { >+ struct tm *stm; >++ time_t _ts; >+ >+- stm=arj_localtime((time_t*)&ts); >++ _ts = ts; >++ >++ stm=arj_localtime(&_ts); >+ return(get_tstamp(stm->tm_year+1900, stm->tm_mon+1, stm->tm_mday, >+ stm->tm_hour, stm->tm_min, stm->tm_sec)); >+ } > >Property changes on: files/patch-arjtypes.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-decode.c >=================================================================== >--- files/patch-decode.c (nonexistent) >+++ files/patch-decode.c (working copy) >@@ -0,0 +1,53 @@ >+--- decode.c 2017-07-31 09:00:00 UTC >++++ decode.c >+@@ -255,7 +255,7 @@ void read_pt_len(int nn, int nbit, int i >+ if(i==i_special) >+ { >+ c=getbits(2); >+- while(--c>=0) >++ while(--c>=0&&i<nn) >+ pt_len[i++]=0; >+ } >+ } >+@@ -314,10 +314,10 @@ void read_c_len() >+ c=getbits(CBIT); >+ c+=20; >+ } >+- while(--c>=0) >++ while(--c>=0&&i<NC) >+ c_len[i++]=0; >+ } >+- else >++ else if (i<NC) >+ c_len[i++]=(unsigned char)(c-2); >+ } >+ while(i<NC) >+@@ -416,10 +416,10 @@ static void NEAR decode_end() >+ >+ void decode(int action) >+ { >+- short i; >+- short r; >+- short c; >+- static short j; >++ int i; >++ int r; >++ int c; >++ static int j; >+ >+ #if SFX_LEVEL>=ARJSFXV >+ if(!setjmp(decode_proc)) >+@@ -450,9 +450,12 @@ void decode(int action) >+ { >+ j=c-(UCHAR_MAX+1-THRESHOLD); >+ count-=(unsigned long)j; >+- i=r-decode_p()-1; >++ int P = decode_p(); >++ i=r-P-1; >+ if(i<0) >+ i+=DICSIZ; >++ if(i<0) >++ goto termination; >+ if(r>i&&r<DICSIZ-MAXMATCH-1) >+ { >+ while(--j>=0) > >Property changes on: files/patch-decode.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-environ.c >=================================================================== >--- files/patch-environ.c (revision 448024) >+++ files/patch-environ.c (working copy) >@@ -1,6 +1,23 @@ > --- environ.c.orig 2004-06-18 16:19:36 UTC > +++ environ.c >-@@ -2058,7 +2058,7 @@ FILE *file_open(char *name, char *mode) >+@@ -1087,6 +1087,8 @@ static char *validate_path(char *name) >+ if(action!=VALIDATE_DRIVESPEC) >+ { >+ #endif >++ while (name[0]!='\0'&& >++ (name[0]=='.'||name[0]==PATHSEP_DEFAULT||name[0]==PATHSEP_UNIX)) { >+ if(name[0]=='.') >+ { >+ if(name[1]=='.'&&(name[2]==PATHSEP_DEFAULT||name[2]==PATHSEP_UNIX)) >+@@ -1096,6 +1098,7 @@ static char *validate_path(char *name) >+ } >+ if(name[0]==PATHSEP_DEFAULT||name[0]==PATHSEP_UNIX) >+ name++; /* "\\" - revert to root */ >++ } >+ #if SFX_LEVEL>=ARJSFXV >+ } >+ } >+@@ -2058,7 +2061,7 @@ FILE *file_open(char *name, char *mode) > /* ASR fix 01/10/2003 -- re-fix to handle umask 022 correctly */ > if((handle=open(name, oflag, 0644))==-1) > return(NULL); >Index: files/patch-fardata.c >=================================================================== >--- files/patch-fardata.c (revision 448024) >+++ files/patch-fardata.c (working copy) >@@ -1,6 +1,15 @@ > --- fardata.c.orig 2004-04-17 11:39:42 UTC > +++ fardata.c >-@@ -190,7 +190,7 @@ int msg_sprintf(char *str, FMSG *fmt, .. >+@@ -52,7 +52,7 @@ int error_proc(FMSG *errmsg, ...) >+ /* Check if the message could have a standard error code */ >+ if(errno!=0&&is_std_error(errmsg)) >+ { >+- msg_cprintf(0, lf); >++ msg_cprintf(0, "\n"); >+ error_report(); >+ } >+ #endif >+@@ -190,7 +190,7 @@ int msg_sprintf(char *str, FMSG *fmt, ...) > > /* Length-limited strlen() */ > >@@ -9,7 +18,36 @@ > { > const char FAR *sc; > >-@@ -569,7 +569,7 @@ int vcprintf(int ccode, FMSG *fmt, va_li >+@@ -377,10 +377,10 @@ static void flush_cbuf(int ccode, char *text) >+ { >+ #if SFX_LEVEL>=ARJSFXV >+ fprintf(new_stdout, strform, n_text); >+- fprintf(new_stdout, lf); >++ fprintf(new_stdout, "\n"); >+ #else >+ printf(strform, n_text); >+- printf(lf); >++ printf("\n"); >+ #endif >+ } >+ else >+@@ -391,13 +391,13 @@ static void flush_cbuf(int ccode, char *text) >+ #ifdef NEED_CRLF >+ scr_out("\r"); >+ #endif >+- scr_out(lf); >++ scr_out("\n"); >+ } >+ if(!no_colors) >+ textcolor(color_table[ccode&H_COLORMASK].color); >+ #else >+ printf(strform, n_text); >+- printf(lf); >++ printf("\n"); >+ #endif >+ n_text=t_text+1; >+ #if SFX_LEVEL>=ARJ >+@@ -569,7 +569,7 @@ int vcprintf(int ccode, FMSG *fmt, va_list args) > if(!s) > s="(null)"; > #endif >@@ -18,7 +56,7 @@ > if(!(flags&LEFT)) > { > while(len<field_width--) >-@@ -655,7 +655,7 @@ int vcprintf(int ccode, FMSG *fmt, va_li >+@@ -655,7 +655,7 @@ int vcprintf(int ccode, FMSG *fmt, va_list args) > num=va_arg(args, unsigned long); > else if(qualifier=='h') > { >Index: files/patch-gnu_makefile.in >=================================================================== >--- files/patch-gnu_makefile.in (nonexistent) >+++ files/patch-gnu_makefile.in (working copy) >@@ -0,0 +1,176 @@ >+--- gnu/makefile.in.orig 2004-04-17 13:28:06 UTC >++++ gnu/makefile.in >+@@ -159,13 +159,16 @@ $(SFXSTUB_DIR)/%.o: $(SRC_DIR)/%.c >+ # Main dependency tree >+ # >+ >+-.PHONY: timestamp prepare cleanup package help >++.PHONY: timestamp msg-headers depends prepare clean package help >+ >+ ifdef COMMERCIAL >+ MAKE_KEY=$(TOOLS_DIR)/make_key$x >+ endif >+ >+-all: prepare timestamp >++all: prepare >++ $(MAKE) timestamp >++ $(MAKE) msg-headers >++ $(MAKE) depends >+ $(MAKE) do-all >+ >+ do-all: \ >+@@ -175,9 +178,29 @@ do-all: \ >+ $(REGISTER_DIR)/$(REGISTER)$x \ >+ $(ARJDISP_DIR)/arjdisp$x \ >+ $(TOOLS_DIR)/packager$x \ >+- $(MAKE_KEY) \ >+- dispose >++ $(MAKE_KEY) >+ >++MSG_ID := \ >++ msg_crp msg_stb msg_sfv msg_sfx msg_sfj msg_arj msg_rej msg_reg msg_adi >++MSG_HEADERS := $(patsubst %,$(BASEDIR)/%.h,$(MSG_ID)) >++ >++msg-headers: $(MSG_HEADERS) >++ >++.deps: >++ mkdir -p $@ >++ >++.deps/%.d: %.c .deps >++ $(CC) $(CPPFLAGS) $(COPT) $< -MM > $@ >++ >++SOURCES = $(wildcard *.c) >++DEPS = $(addprefix .deps/,$(SOURCES:.c=.d)) >++ >++ifeq ($(sort $(DEPS)),$(sort $(wildcard .deps/*.d))) >++include $(DEPS) >++endif >++ >++depends: $(DEPS) >++ >+ # >+ # Update timestamp file >+ # >+@@ -186,12 +209,6 @@ timestamp: $(TOOLS_DIR)/today$x >+ $(TOOLS_DIR)/today$x $(LOCALE) $(BASEDIR) >+ >+ # >+-# Final cleanup >+-# >+- >+-dispose: >+- >+-# >+ # The tools >+ # >+ >+@@ -255,7 +272,7 @@ $(ARJCRYPT_DIR)/arjcrypt$d: $(ARJCRYPT_OBJS) $(TOOLS_D >+ $(CC) $(ALL_CFLAGS) $(DLL_FLAGS) -o $@ $(ARJCRYPT_OBJS) $(ARJCRYPT_DEF) $(LIBS) >+ $(TOOLS_DIR)/postproc $@ >+ >+-$(BASEDIR)/nmsg_crp.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/nmsg_crp.c $(BASEDIR)/msg_crp.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_crp $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -269,7 +286,7 @@ $(SFXSTUB_DIR)/sfxstub$x: $(SFXSTUB_OBJS) $(TOOLS_DIR) >+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(SFXSTUB_OBJS) $(LIBS) >+ $(TOOLS_DIR)/postproc$x $@ -sfx >+ >+-$(BASEDIR)/nmsg_stb.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/nmsg_stb.c $(BASEDIR)/msg_stb.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_stb $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -287,7 +304,8 @@ $(ARJSFXV_DIR)/arjsfxv$x: $(ARJSFXV_OBJS) $(TOOLS_DIR) >+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(ARJSFXV_OBJS) $(LIBS) $(DYN_LIBS) >+ $(TOOLS_DIR)/postproc$x $@ -sfx >+ >+-$(BASEDIR)/fmsg_sfv.c $(BASEDIR)/imsg_sfv.c $(BASEDIR)/nmsg_sfv.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/fmsg_sfv.c $(BASEDIR)/imsg_sfv.c $(BASEDIR)/nmsg_sfv.c \ >++$(BASEDIR)/msg_sfv.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_sfv $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -304,7 +322,8 @@ $(ARJSFX_DIR)/arjsfx$x: $(ARJSFX_OBJS) $(TOOLS_DIR)/po >+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(ARJSFX_OBJS) $(LIBS) >+ $(TOOLS_DIR)/postproc$x $@ -sfx >+ >+-$(BASEDIR)/fmsg_sfx.c $(BASEDIR)/imsg_sfx.c $(BASEDIR)/nmsg_sfx.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/fmsg_sfx.c $(BASEDIR)/imsg_sfx.c $(BASEDIR)/nmsg_sfx.c \ >++$(BASEDIR)/msg_sfx.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_sfx $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -319,7 +338,8 @@ $(ARJSFXJR_DIR)/arjsfxjr$x: $(ARJSFXJR_OBJS) $(TOOLS_D >+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(ARJSFXJR_OBJS) $(LIBS) >+ $(TOOLS_DIR)/postproc$x $@ -sfx >+ >+-$(BASEDIR)/fmsg_sfj.c $(BASEDIR)/imsg_sfj.c $(BASEDIR)/nmsg_sfj.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/fmsg_sfj.c $(BASEDIR)/imsg_sfj.c $(BASEDIR)/nmsg_sfj.c \ >++$(BASEDIR)/msg_sfj.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_sfj $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -354,7 +374,8 @@ $(ARJ_DIR)/arj$x: $(ARJ_OBJS) \ >+ $(TOOLS_DIR)/join $(ARJ_DIR)/arj$x $(BASEDIR)/help.arj >+ $(TOOLS_DIR)/postproc $@ >+ >+-$(BASEDIR)/fmsg_arj.c $(BASEDIR)/imsg_arj.c $(BASEDIR)/nmsg_arj.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/fmsg_arj.c $(BASEDIR)/imsg_arj.c $(BASEDIR)/nmsg_arj.c \ >++$(BASEDIR)/msg_arj.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_arj $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -372,7 +393,8 @@ $(REARJ_DIR)/rearj$x: $(REARJ_OBJS) \ >+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(REARJ_OBJS) $(LIBS) >+ $(TOOLS_DIR)/postproc $@ >+ >+-$(BASEDIR)/fmsg_rej.c $(BASEDIR)/imsg_rej.c $(BASEDIR)/nmsg_rej.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/fmsg_rej.c $(BASEDIR)/imsg_rej.c $(BASEDIR)/nmsg_rej.c \ >++$(BASEDIR)/msg_rej.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_rej $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -388,7 +410,8 @@ $(REGISTER_DIR)/$(REGISTER)$x: $(REGISTER_OBJS) \ >+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(REGISTER_OBJS) $(LIBS) >+ $(TOOLS_DIR)/postproc $@ -sfx >+ >+-$(BASEDIR)/fmsg_reg.c $(BASEDIR)/imsg_reg.c $(BASEDIR)/nmsg_reg.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/fmsg_reg.c $(BASEDIR)/imsg_reg.c $(BASEDIR)/nmsg_reg.c \ >++$(BASEDIR)/msg_reg.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_reg $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -402,7 +425,8 @@ ARJDISP_OBJS = $(patsubst %,$(ARJDISP_DIR)/%, \ >+ $(ARJDISP_DIR)/arjdisp$x: $(ARJDISP_OBJS) >+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(ARJDISP_OBJS) $(LIBS) >+ >+-$(BASEDIR)/fmsg_adi.c $(BASEDIR)/imsg_adi.c $(BASEDIR)/nmsg_adi.c: $(TOOLS_DIR)/msgbind$x $(RESFILE) >++$(BASEDIR)/fmsg_adi.c $(BASEDIR)/imsg_adi.c $(BASEDIR)/nmsg_adi.c \ >++$(BASEDIR)/msg_adi.h: $(TOOLS_DIR)/msgbind$x $(RESFILE) >+ $(TOOLS_DIR)/msgbind $(RESFILE) msg_adi $(OS_ID) $(PACKAGE) $(LOCALE) $(BASEDIR) >+ >+ # >+@@ -427,18 +451,9 @@ prepare: >+ # >+ >+ clean: >+- -rm -f $(BASEDIR)/* >+- -rm -f $(TOOLS_DIR)/* >+- -rm -f $(ARJCRYPT_DIR)/* >+- -rm -f $(SFXSTUB_DIR)/* >+- -rm -f $(ARJSFXV_DIR)/* >+- -rm -f $(ARJSFX_DIR)/* >+- -rm -f $(ARJSFXJR_DIR)/* >+- -rm -f $(ARJ_DIR)/* >+- -rm -f $(REARJ_DIR)/* >+- -rm -f $(REGISTER_DIR)/* >+- -rm -f $(ARJDISP_DIR)/* >+- -rm -f arj.core >++ rm -rf .deps >++ rm -rf $(BASEDIR) >++ rm -f arj.core >+ >+ # >+ # Local installation > >Property changes on: files/patch-gnu_makefile.in >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-rearj.c >=================================================================== >--- files/patch-rearj.c (nonexistent) >+++ files/patch-rearj.c (working copy) >@@ -0,0 +1,11 @@ >+--- rearj.c.orig 2017-08-16 08:08:49 UTC >++++ rearj.c >+@@ -935,7 +935,7 @@ static int convert_archive(char *name) >+ msg_cprintf(H_HL|H_NFMT, M_OLD_SIZE, old_fsize); >+ msg_cprintf(H_HL|H_NFMT, M_NEW_SIZE, new_fsize); >+ msg_cprintf(H_HL|H_NFMT, M_SAVINGS_SIZE, gain); >+- printf(lf); >++ printf("\n"); >+ total_old_fsize+=old_fsize; >+ total_new_fsize+=new_fsize; >+ total_files++; > >Property changes on: files/patch-rearj.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-register.c >=================================================================== >--- files/patch-register.c (nonexistent) >+++ files/patch-register.c (working copy) >@@ -0,0 +1,11 @@ >+--- register.c.orig 2004-04-21 07:04:10 UTC >++++ register.c >+@@ -205,7 +205,7 @@ int main(int argc, char **argv) >+ char reg_source[200]; >+ int i; >+ >+- printf(M_REGISTER_BANNER); >++ fputs(M_REGISTER_BANNER, stdout); >+ integrity_pattern[0]--; >+ build_crc32_table(); >+ if(argc!=2) > >Property changes on: files/patch-register.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-uxspec.c >=================================================================== >--- files/patch-uxspec.c (nonexistent) >+++ files/patch-uxspec.c (working copy) >@@ -0,0 +1,70 @@ >+--- uxspec.c.orig 2004-04-17 13:39:42 UTC >++++ uxspec.c >+@@ -120,6 +120,58 @@ int query_uxspecial(char FAR **dest, char *name, struc >+ } >+ #endif >+ >++#if TARGET==UNIX >++static int is_link_traversal(const char *name) >++{ >++ enum { >++ STATE_NONE, >++ STATE_DOTS, >++ STATE_NAME, >++ } state = STATE_NONE; >++ int ndir = 0; >++ int dots = 0; >++ >++ while(*name) { >++ int c = *name++; >++ >++ if (c == '/') >++ { >++ if ((state == STATE_DOTS) && (dots == 2)) >++ ndir--; >++ if (ndir < 0) >++ return 1; >++ if ((state == STATE_DOTS && dots == 1) && ndir == 0) >++ return 1; >++ if (state == STATE_NONE && ndir == 0) >++ return 1; >++ if ((state == STATE_DOTS) && (dots > 2)) >++ ndir++; >++ state = STATE_NONE; >++ dots = 0; >++ } >++ else if (c == '.') >++ { >++ if (state == STATE_NONE) >++ state = STATE_DOTS; >++ dots++; >++ } >++ else >++ { >++ if (state == STATE_NONE) >++ ndir++; >++ state = STATE_NAME; >++ } >++ } >++ >++ if ((state == STATE_DOTS) && (dots == 2)) >++ ndir--; >++ if ((state == STATE_DOTS) && (dots > 2)) >++ ndir++; >++ >++ return ndir < 0; >++} >++#endif >++ >+ /* Restores the UNIX special file data */ >+ >+ int set_uxspecial(char FAR *storage, char *name) >+@@ -156,6 +208,8 @@ int set_uxspecial(char FAR *storage, char *name) >+ l=sizeof(tmp_name)-1; >+ far_memmove((char FAR *)tmp_name, dptr, l); >+ tmp_name[l]='\0'; >++ if (is_link_traversal(tmp_name)) >++ return(UXSPEC_RC_ERROR); >+ rc=(id==UXSB_HLNK)?link(tmp_name, name):symlink(tmp_name, name); >+ if(!rc) >+ return(0); > >Property changes on: files/patch-uxspec.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property
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 221589
:
185526
|
187288