rpms/openoffice.org/devel openoffice.org-3.1.1.oooXXXXX.dmake.patch, 1.1, 1.2

Caolan McNamara caolanm at fedoraproject.org
Fri Aug 7 19:50:44 UTC 2009


Author: caolanm

Update of /cvs/pkgs/rpms/openoffice.org/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv27064

Modified Files:
	openoffice.org-3.1.1.oooXXXXX.dmake.patch 
Log Message:
first set of overlaps in dmake

openoffice.org-3.1.1.oooXXXXX.dmake.patch:
 dag.c      |    9 ++++++---
 expand.c   |    6 ++++--
 getinp.c   |    6 ++++--
 path.c     |   10 +++++++---
 rulparse.c |    2 +-
 5 files changed, 22 insertions(+), 11 deletions(-)

Index: openoffice.org-3.1.1.oooXXXXX.dmake.patch
===================================================================
RCS file: /cvs/pkgs/rpms/openoffice.org/devel/openoffice.org-3.1.1.oooXXXXX.dmake.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- openoffice.org-3.1.1.oooXXXXX.dmake.patch	29 Jul 2009 12:37:35 -0000	1.1
+++ openoffice.org-3.1.1.oooXXXXX.dmake.patch	7 Aug 2009 19:50:44 -0000	1.2
@@ -1,4 +1,5 @@
---- dmake/rulparse.c	2009-07-29 13:31:47.000000000 +0100
+diff -ru dmake.orig/rulparse.c dmake/rulparse.c
+--- dmake.orig/rulparse.c	2009-07-29 13:31:47.000000000 +0100
 +++ dmake/rulparse.c	2009-07-29 13:32:09.000000000 +0100
 @@ -897,7 +897,7 @@
  	 /* Handle %-targets. */
@@ -9,3 +10,113 @@
  
  #ifdef DBUG
  	 DB_PRINT( "%", ("Handling %%-target [%s : : <prerequisites follow, maybe empty>]",
+diff -ru dmake.orig/dag.c dmake/dag.c
+--- dmake.orig/dag.c	2009-08-07 20:18:31.000000000 +0100
++++ dmake/dag.c	2009-08-07 20:30:59.000000000 +0100
+@@ -369,14 +369,17 @@
+ 	 /* strip out any \<nl> combinations where \ is the current
+ 	  * CONTINUATION char */
+ 	 for(p=q; (p=strchr(p,CONTINUATION_CHAR))!=NIL(char); )
+-	    if( p[1] == '\n' )
+-	       strcpy( p, p+2 );
++	    if( p[1] == '\n' ) {
++	       size_t len = strlen(p+2)+1;
++	       memmove ( p, p+2, len );
++	    }
+ 	    else
+ 	       p++;
+ 
+ 	 p = DmStrSpn(q ," \t");	/* Strip white space before ... */
+ 	 if( p != q ) {
+-	    strcpy( q, p);
++	    size_t len = strlen(p)+1;
++	    memmove( q, p, len );
+ 	    p = q;
+ 	 }
+ 
+diff -ru dmake.orig/expand.c dmake/expand.c
+--- dmake.orig/expand.c	2009-08-07 20:18:34.000000000 +0100
++++ dmake/expand.c	2009-08-07 20:42:40.000000000 +0100
+@@ -365,7 +365,8 @@
+       if( (e = Basename(s)) != s) {
+ 	 if( !(mod & DIRECTORY_FLAG) ) {
+ 	    /* Move the basename to the start. */
+-	    strcpy(s, e);
++	    size_t len = strlen(e)+1;
++	    memmove(s, e, len);
+ 	 }
+ 	 else
+ 	    s = e;
+@@ -382,7 +383,8 @@
+ 
+       if( !(mod & FILE_FLAG) ) {
+ 	 /* Move the suffix to the start. */
+-	 strcpy( s, e );
++	 size_t len = strlen(e)+1;
++	 memmove( s, e, len );
+       }
+       else
+ 	 s = e;
+diff -ru dmake.orig/getinp.c dmake/getinp.c
+--- dmake.orig/getinp.c	2009-08-07 20:18:31.000000000 +0100
++++ dmake/getinp.c	2009-08-07 20:27:08.000000000 +0100
+@@ -169,7 +169,8 @@
+ 	  * text lines on input.  The maximum size of this is governened by
+ 	  * Buffer_size */
+ 	    if( q != p && q[-1] == CONTINUATION_CHAR ) {
+-	       strcpy( q, q+1 );
++	       size_t len = strlen(q+1)+1;
++	       memmove( q, q+1, len );
+ 	       q--;
+ 	       cont = FALSE;
+ 	    }
+@@ -290,7 +291,8 @@
+    while( (c = strchr(c, COMMENT_CHAR)) != NIL(char) ) {
+       if( Comment || State == NORMAL_SCAN )
+ 	 if( c != str && c[-1] == ESCAPE_CHAR ) {
+-	    strcpy( c-1, c );        /* copy it left, due to \# */
++	    size_t len = strlen(c)+1;
++	    memmove( c-1, c, len );  /* copy it left, due to \# */
+ 	    if( pend ) (*pend)--;    /* shift tail pointer left */
+ 	 }
+ 	 else {
+diff -ru dmake.orig/path.c dmake/path.c
+--- dmake.orig/path.c	2009-08-07 20:18:31.000000000 +0100
++++ dmake/path.c	2009-08-07 20:41:30.000000000 +0100
+@@ -172,6 +172,7 @@
+    char *tpath;
+    int hasdriveletter = 0;
+    int delentry;
++   size_t len;
+ 
+    DB_ENTER( "Clean_path" );
+ 
+@@ -231,14 +232,16 @@
+ 	    p++;
+ 	 }
+ 	 while( *p == *DirSepStr);
+-	 strcpy(t+1,p);
++	 len = strlen(p)+1;
++	 memmove(t+1,p,len);
+ 	 continue;
+       }
+ 
+       /* Remove './'. If OOODMAKEMODE is set do this only if it is not at
+        * the start of the path. */
+       if ( p-q == 1 && *q == '.' && (q != path || !STOBOOL(OOoDmMode)) ) {
+-	 strcpy(q,p+1);
++	 len = strlen(p+1)+1;
++	 memmove(q,p+1,len);
+ 	 q = tpath;
+ 	 continue;
+       }
+@@ -268,7 +271,8 @@
+ 	 }
+ 	 while( *t == *DirSepStr);
+ 	 /* q points to first letter of the current directory/file. */
+-	 strcpy(q,t);
++	 len = strlen(t)+1;
++	 memmove(q,t,len);
+ 	 q = tpath;
+       }
+       else




More information about the scm-commits mailing list