patch to track errors from egcs_update

Robert Lipe robertlipe@usa.net
Mon Feb 1 22:15:00 GMT 1999


If egcs_update is called by a script instead of a human, propogating
error return values back upstream is nice.

	* egcs_update: Test return values of 'cvs update'.  Propogate 
	to caller as exit values.


Index: egcs_update
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/contrib/egcs_update,v
retrieving revision 1.13
diff -c -5 -p -r1.13 egcs_update
*** egcs_update	1999/01/25 14:10:09	1.13
--- egcs_update	1999/02/02 06:14:17
*************** do
*** 56,69 ****
--- 56,77 ----
      if [ -f $i -a -d $D ]; then 
          echo $i
      fi
  done`
  cvs -q update $X
+ if [ $? -ne 0 ] ; then 
+     echo "CVS update of generated files failed." >&2
+     exit 1
+ fi
  
  
  echo "Pass 2: Updating full tree"
  cvs -q update ${1+"$@"}
+ if [ $? -ne 0 ] ; then 
+     echo "CVS update of full tree failed." >&2
+     exit 1
+ fi
  
  echo "Pass 3: Fixing local tree"
  # Please also update the FAQ accordingly if you change the list of
  # files below. Note that generated files should be touched only
  # after the corresponding *.y files.


More information about the Gcc-patches mailing list