FreeBSD Bugzilla – Attachment 193211 Details for
Bug 228100
sysutils/ods2 [PATCH] and request maintainership
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
include patch-ods2 patch-direct.c patch-Makefile
patch-all (text/plain), 4.11 KB, created by
Oleg P.
on 2018-05-09 15:56:47 UTC
(
hide
)
Description:
include patch-ods2 patch-direct.c patch-Makefile
Filename:
MIME Type:
Creator:
Oleg P.
Created:
2018-05-09 15:56:47 UTC
Size:
4.11 KB
patch
obsolete
>--- ods2.c.orig 2001-09-08 01:17:04.000000000 +0400 >+++ ods2.c 2018-05-06 10:07:53.678876000 +0300 >@@ -1076,10 +1076,17 @@ > int main(int argc,char *argv[]) > { > char str[2048]; >+ char *ptr; >+ int iargc, i, ilen, len; >+ int cmdline = 0; > FILE *atfile = NULL; >+ > printf(" ODS2 %s\n", MODULE_IDENT); >+ if (argc>1) { /* if exist argument in the command line TRUE */ >+ cmdline = 1; >+ iargc = argc - 1; >+ } > while (1) { >- char *ptr; > if (atfile != NULL) { > if (fgets(str,sizeof(str),atfile) == NULL) { > fclose(atfile); >@@ -1090,18 +1097,50 @@ > if (ptr != NULL) *ptr = '\0'; > printf("$> %s\n",str); > } >+ } >+ else if (cmdline) { >+ ptr = str; >+ for ( len=0, ilen=0, i=argc-iargc; i<argc; i++ ) >+ if ( *argv[i] == '$' ) { >+ iargc--; >+ break; >+ } else { >+ ilen = strlen(argv[i]); >+ len +=ilen; >+ if (len < sizeof(str)) { >+ strcpy(ptr, argv[i]); >+ ptr += ilen; >+ *ptr = ' '; >+ ptr++; *ptr = '\0'; >+ iargc--; >+ } else { >+ printf("%%ODS2-CMD-LINE, len of arguments too long.\n"); >+ break; >+ } >+ } >+ if (iargc == 0) cmdline = 0; /* if all arguments execute */ >+ if (ptr != str) printf("$> %s\n",str); > } else { > #ifdef VMS >- if (getcmd (str, "$> ") == NULL) break; >+ if (getcmd (str, "$> ") == NULL) break; > #else >- printf("$> "); >- if (gets(str) == NULL) break; >+ printf("$> "); >+ if (fgets(str, sizeof(str), stdin) == NULL) >+ break; >+ str[strlen(str)-1] = '\0'; /* strip newline from str */ > #endif >- } >+ } /* if - else if - else */ > ptr = str; >- while (*ptr == ' ' || *ptr == '\t') ptr++; >- if (strlen(ptr) && *ptr != '!') { >+ while (*ptr == ' ' || *ptr == '\t') ptr++; /* space and tab */ >+ len = strlen(ptr); >+ if (len && *ptr != '!') { > if (*ptr == '@') { >+ len--; >+ /* remove trailing spaces and tabs */ >+ while (*(ptr+len) == ' ' || *(ptr+len) == '\t') { >+ *(ptr+len) = '\0'; >+ len--; >+ } > if (atfile != NULL) { > printf("%%ODS2-W-INDIRECT, indirect indirection not permitted\n"); > } else { >@@ -1112,9 +1151,9 @@ > } > } else { > if ((cmdsplit(ptr) & 1) == 0) break; >- } >- } >- } >+ } /* else */ >+ } /* if */ >+ } /* while (1) */ > if (atfile != NULL) fclose(atfile); > return 1; > } >====================================== >--- direct.c.orig 2001-08-31 22:01:07.000000000 +0400 >+++ direct.c 2018-05-06 20:04:41.264004000 +0300 >@@ -136,12 +136,15 @@ > register char sch = *name; > if (sch != '*') { > register char ech = *entry; >- if (sch != ech) if (toupper(sch) != toupper(ech)) >- if (sch == '%') { >- percent = MAT_NE; >- } else { >- break; >- } >+ if (sch != ech) { >+ if (toupper(sch) != toupper(ech)) { >+ if (sch == '%') { >+ percent = MAT_NE; >+ } else { >+ break; >+ } >+ } >+ } > } else { > break; > } >====================================== >--- Makefile.orig 2016-03-07 17:59:02.000000000 +0300 >+++ Makefile 2018-05-06 18:18:01.072166000 +0300 >@@ -7,7 +7,7 @@ > MASTER_SITES= http://www.lugs.ch/~dussuett/ > DISTNAME= ods2 > >-MAINTAINER= ports@FreeBSD.org >+MAINTAINER= pzn.unixbsd@gmail.com > COMMENT= Utility for manipulating ODS-2 filesystems > > USES= zip
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 Raw
Actions:
View
Attachments on
bug 228100
:
193211
|
193212
|
193213
|
193214
|
193225