summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/cvs/diff
diff options
context:
space:
mode:
authorThorsten Lockert <tholo@cvs.openbsd.org>1999-09-10 05:06:42 +0000
committerThorsten Lockert <tholo@cvs.openbsd.org>1999-09-10 05:06:42 +0000
commitcd99c1703e7a27d21741a2b814c1ec61bd6301d2 (patch)
tree426d689f4d40078e79c1dbef327dec1feca59e41 /gnu/usr.bin/cvs/diff
parent1432381c350561abe51a1f10481863c7740f29d6 (diff)
Latest version from Cyclic
Diffstat (limited to 'gnu/usr.bin/cvs/diff')
-rw-r--r--gnu/usr.bin/cvs/diff/.cvsignore3
-rw-r--r--gnu/usr.bin/cvs/diff/ChangeLog35
-rw-r--r--gnu/usr.bin/cvs/diff/diff.c3
-rw-r--r--gnu/usr.bin/cvs/diff/diff3.c10
-rw-r--r--gnu/usr.bin/cvs/diff/libdiff.dsp134
5 files changed, 180 insertions, 5 deletions
diff --git a/gnu/usr.bin/cvs/diff/.cvsignore b/gnu/usr.bin/cvs/diff/.cvsignore
new file mode 100644
index 00000000000..be755f8b416
--- /dev/null
+++ b/gnu/usr.bin/cvs/diff/.cvsignore
@@ -0,0 +1,3 @@
+Makefile
+Debug
+Release
diff --git a/gnu/usr.bin/cvs/diff/ChangeLog b/gnu/usr.bin/cvs/diff/ChangeLog
index 90ba69b11b9..a43518258d0 100644
--- a/gnu/usr.bin/cvs/diff/ChangeLog
+++ b/gnu/usr.bin/cvs/diff/ChangeLog
@@ -1,3 +1,38 @@
+1999-05-06 Jim Kingdon <http://www.cyclic.com>
+
+ * Makefile.in (DISTFILES): Remove libdiff.mak.
+ * libdiff.mak: Removed; we are back to a single makefile for
+ Visual C++ version 4.
+
+1999-04-29 Jim Kingdon <http://www.cyclic.com>
+
+ * diff.c (diff_run): Use separate statement for setjmp call and if
+ statement. This is better style in general (IMHO) but in the case
+ of setjmp the UNICOS compiler apparently cares (I don't have the
+ standard handy, but there are lots of legitimate restrictions on
+ how you can call setjmp).
+
+1999-04-26 Jim Kingdon <http://www.cyclic.com>
+
+ * Makefile.in (DISTFILES): Add libdiff.dsp libdiff.mak .cvsignore.
+
+1999-04-26 (submitted 1999-03-24) John O'Connor <john@shore.net>
+
+ * libdiff.dsp: new file. MSVC project file used to build the library.
+
+ * libdiff.mak: new file. Makefile for building from the command-line.
+
+ * .cvsignore: Removed un-used entries related to MSVC. Added
+ entries to ignore directories generated by the NT build, Debug
+ and Release.
+
+1999-03-24 Larry Jones <larry.jones@sdrc.com>
+ and Olaf Brandes
+
+ * diff3.c (diff3_run): Use a separate stream for the input to
+ output_diff3_merge instead of reopening stdin to avoid problems
+ with leaving it open.
+
1999-02-17 Jim Kingdon <http://www.cyclic.com>
and Hallvard B Furuseth.
diff --git a/gnu/usr.bin/cvs/diff/diff.c b/gnu/usr.bin/cvs/diff/diff.c
index bc951c4105f..e5f7e42bfcd 100644
--- a/gnu/usr.bin/cvs/diff/diff.c
+++ b/gnu/usr.bin/cvs/diff/diff.c
@@ -688,7 +688,8 @@ diff_run (argc, argv, out, callbacks_arg)
/* Set the jump buffer, so that diff may abort execution without
terminating the process. */
- if ((val = setjmp (diff_abort_buf)) != 0)
+ val = setjmp (diff_abort_buf);
+ if (val != 0)
{
optind = optind_old;
if (opened_file)
diff --git a/gnu/usr.bin/cvs/diff/diff3.c b/gnu/usr.bin/cvs/diff/diff3.c
index 65b783b3e67..e3be1503e86 100644
--- a/gnu/usr.bin/cvs/diff/diff3.c
+++ b/gnu/usr.bin/cvs/diff/diff3.c
@@ -457,13 +457,15 @@ diff3_run (argc, argv, out, callbacks_arg)
tag_strings[0], tag_strings[1], tag_strings[2]);
else if (merge)
{
- if (! freopen (file[rev_mapping[FILE0]], "r", stdin))
+ FILE *mfp = fopen (file[rev_mapping[FILE0]], "r");
+ if (! mfp)
diff3_perror_with_exit (file[rev_mapping[FILE0]]);
- conflicts_found
- = output_diff3_merge (stdin, diff3, mapping, rev_mapping,
+ conflicts_found = output_diff3_merge (mfp, diff3, mapping, rev_mapping,
tag_strings[0], tag_strings[1], tag_strings[2]);
- if (ferror (stdin))
+ if (ferror (mfp))
diff3_fatal ("read error");
+ if (fclose(mfp) != 0)
+ perror_with_name (file[rev_mapping[FILE0]]);
}
else
{
diff --git a/gnu/usr.bin/cvs/diff/libdiff.dsp b/gnu/usr.bin/cvs/diff/libdiff.dsp
new file mode 100644
index 00000000000..90cda23e84c
--- /dev/null
+++ b/gnu/usr.bin/cvs/diff/libdiff.dsp
@@ -0,0 +1,134 @@
+# Microsoft Developer Studio Project File - Name="libdiff" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 5.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Static Library" 0x0104
+
+CFG=libdiff - Win32 Release
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "libdiff.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "libdiff.mak" CFG="libdiff - Win32 Release"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "libdiff - Win32 Release" (based on "Win32 (x86) Static Library")
+!MESSAGE "libdiff - Win32 Debug" (based on "Win32 (x86) Static Library")
+!MESSAGE
+
+# Begin Project
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+
+!IF "$(CFG)" == "libdiff - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ".\libdiff"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Target_Dir ".\libdiff"
+# ADD BASE CPP /nologo /W3 /GX /O2 /I "..\windows-NT" /I "..\lib" /D "_WINDOWS" /D "HAVE_TIME_H" /D "CLOSEDIR_VOID" /D "NDEBUG" /D "WIN32" /D "WANT_WIN_COMPILER_VERSION" /YX /FD /c
+# ADD CPP /nologo /W3 /GX /O2 /I "..\windows-NT" /I "..\lib" /D "_WINDOWS" /D "HAVE_TIME_H" /D "CLOSEDIR_VOID" /D "NDEBUG" /D "WIN32" /D "WANT_WIN_COMPILER_VERSION" /YX /FD /c
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo
+# ADD LIB32 /nologo
+
+!ELSEIF "$(CFG)" == "libdiff - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ".\libdiff"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Target_Dir ".\libdiff"
+# ADD BASE CPP /nologo /W3 /GX /Z7 /Od /I "..\windows-NT" /I "..\lib" /D "_DEBUG" /D "_WINDOWS" /D "WIN32" /D "HAVE_TIME_H" /D "CLOSEDIR_VOID" /YX /FD /c
+# ADD CPP /nologo /W3 /GX /Z7 /Od /I "..\windows-NT" /I "..\lib" /D "_DEBUG" /D "_WINDOWS" /D "WIN32" /D "HAVE_TIME_H" /D "CLOSEDIR_VOID" /YX /FD /c
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo
+# ADD LIB32 /nologo
+
+!ENDIF
+
+# Begin Target
+
+# Name "libdiff - Win32 Release"
+# Name "libdiff - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;hpj;bat;for;f90"
+# Begin Source File
+
+SOURCE=.\analyze.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\cmpbuf.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\context.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\diff.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\diff3.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\dir.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\ed.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\ifdef.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\io.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\normal.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\side.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\util.c
+# End Source File
+# Begin Source File
+
+SOURCE=.\version.c
+# End Source File
+# End Group
+# End Target
+# End Project