Discussion:
Patches
John Poltorak
2004-05-04 10:19:05 UTC
Permalink
Looking at some old patches made by KUR, they seem to have a different
format to others I've see. That's probably due to different diff options
used. Here is an example:-


diff -cbBwr orig/lib/gethostname.c new/lib/gethostname.c
*** orig/lib/gethostname.c Mon Sep 26 23:25:26 1994
--- new/lib/gethostname.c Sat Dec 17 00:09:12 1994
***************
*** 22,28 ****
#endif

#ifdef HAVE_UNAME
! #include <sys/utsname.h>
#endif

/* Put up to LEN chars of the host name into NAME.
--- 22,28 ----
#endif

#ifdef HAVE_UNAME
! #include <utsname.h>
#endif

/* Put up to LEN chars of the host name into NAME.



Can anyone explain any reason for this format?
--
John
Thomas Dickey
2004-05-04 11:32:02 UTC
Permalink
Post by John Poltorak
Looking at some old patches made by KUR, they seem to have a different
format to others I've see. That's probably due to different diff options
used. Here is an example:-
That's a context diff (-c option) the friendler version of the original
diff formats. It uses more lines than unified diff and is reportedly a
little harder to mechanically sync with patch.
Post by John Poltorak
diff -cbBwr orig/lib/gethostname.c new/lib/gethostname.c
*** orig/lib/gethostname.c Mon Sep 26 23:25:26 1994
--- new/lib/gethostname.c Sat Dec 17 00:09:12 1994
***************
*** 22,28 ****
#endif
#ifdef HAVE_UNAME
! #include <sys/utsname.h>
#endif
/* Put up to LEN chars of the host name into NAME.
--- 22,28 ----
#endif
#ifdef HAVE_UNAME
! #include <utsname.h>
#endif
/* Put up to LEN chars of the host name into NAME.
Can anyone explain any reason for this format?
--
John
--
Thomas E. Dickey
http://invisible-island.net
ftp://invisible-island.net
Loading...