This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: avoid obsolete diff -0 option


On my system, GNU diff warns about -0 usage:

  $ diff -ub -0 /dev/null /dev/null
  diff: `-0' option is obsolete; use `-U 0'

This patch corrects it.  Okay for mainline?

2005-07-28  Ben Elliston  <bje@au.ibm.com>

        * scripts/check_jni_methods.sh: Use diff -U 0, not -0.

Index: check_jni_methods.sh
===================================================================
RCS file: /home/bje/gcc-cvs/gcc/libjava/classpath/scripts/check_jni_methods.sh,v
retrieving revision 1.1.1.1.4.1
diff -u -p -u -r1.1.1.1.4.1 check_jni_methods.sh
--- check_jni_methods.sh        20 Jul 2005 04:00:48 -0000      1.1.1.1.4.1
+++ check_jni_methods.sh        28 Jul 2005 00:16:43 -0000
@@ -24,7 +24,7 @@ cat > $TMPFILE3 << EOF
 EOF

 # Compare again silently.
-diff -ub -0 $TMPFILE $TMPFILE2  | grep '^[+-]Java' | grep -q -v -f $TMPFILE3
+diff -ub -U 0 $TMPFILE $TMPFILE2  | grep '^[+-]Java' | grep -q -v -f $TMPFILE3
 RESULT=$?

 if test "$RESULT" = "0" ; then
@@ -32,7 +32,7 @@ if test "$RESULT" = "0" ; then
   echo "(-) missing in implementation, (+) missing in header files"

   # Compare the found method lists.
-  diff -ub -0 $TMPFILE $TMPFILE2  | grep '^[+-]Java' | grep -v -f $TMPFILE3
+  diff -ub -U 0 $TMPFILE $TMPFILE2  | grep '^[+-]Java' | grep -v -f $TMPFILE3
 fi

 # Cleanup.

Attachment: signature.asc
Description: OpenPGP digital signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]