[comp.sources.bugs] lharc fixes
Onno van der Linden
linden at natasha.fwi.uva.nl
Wed Mar 21 06:13:11 AEST 1990
Original-posting-by: linden at natasha.fwi.uva.nl (Onno van der Linden)
Original-subject: lharc fixes
Reposted-by: emv at math.lsa.umich.edu (Edward Vielmetti)
[This is a patch to lharc from comp.sources.bugs.]
Recently,Harry Langenbacher wrote in the last couple of lines
of his posting:
>
>Does anyone know how to get lharc to handle directory names without barfing ?
>
>thanx
>
>
>- Harry Langenbacher 818-354-9513
>harry%neuron1 at jpl-mil.jpl.nasa.gov
>harry at neuron1.jpl.nasa.gov 128.149.12.7
Well, below are the diffs I made for lharc.c and it seems to work OK
on a SUN-4 (SPARCstation 1,to be more specific).
Onno van der Linden
linden at fwi.uva.nl
--------------------------cut here-------------------------------
*** lharc.c Tue Mar 20 10:37:30 1990
--- old/lharc.c Mon Mar 12 10:38:06 1990
***************
*** 24,30 ****
#include <profile.h>
#endif
! /* #define STRICT */
#define FASTCOPY
#ifdef MSDOS
--- 24,30 ----
#include <profile.h>
#endif
! #define STRICT
#define FASTCOPY
#ifdef MSDOS
***************
*** 320,326 ****
char *myname;
! void userbreak()
{
error("Interrupt.");
}
--- 320,326 ----
char *myname;
! void userbreak(void)
{
error("Interrupt.");
}
***************
*** 459,477 ****
print_tiny_usage_and_exit ()
{
! printf("\nC-LHarc for %s Version 1.00 (C) 1989-1990 Y.Tagawa, Kai Uwe Rommel\n\
! \nUsage: %s {axevlufdmctp}[qnftv] archive_file [files or directories...]\n", SYSNAME, myname);
! printf("\nCommands: Options:\n\
! a Append q quiet\n\
! x,e EXtract n no execute\n\
! v,l View/List f force (over write at extract)\n\
! u Update t files are TEXT files\n\
! f Freshen v<pager> use file pager for p command\n\
! d Delete\n\
! m Move\n\
! c re-Construct new archive\n\
! t Test archive\n\
! p Print to STDOUT\n");
exit (1);
}
--- 459,478 ----
print_tiny_usage_and_exit ()
{
! printf("\nC-LHarc for %s Version 1.00 (C) 1989-1990 Y.Tagawa, Kai Uwe Rommel\n"
! "\nUsage: %s {axevlufdmctp}[qnftv] archive_file [files or directories...]\n",
! SYSNAME, myname);
! printf("\nCommands: Options:\n"
! " a Append q quiet\n"
! " x,e EXtract n no execute\n"
! " v,l View/List f force (over write at extract)\n"
! " u Update t files are TEXT files\n"
! " f Freshen v<pager> use file pager for p command\n"
! " d Delete\n"
! " m Move\n"
! " c re-Construct new archive\n"
! " t Test archive\n"
! " p Print to STDOUT\n");
exit (1);
}
***************
*** 1956,1964 ****
if (noexec)
fprintf (stderr, "APPEND %s\n", name);
else
! /* #ifdef STRICT */
if ( !directory )
! /* #endif */
if ( !update_freshen || (cmp == 0) )
append_one (fp, nafp, &hdr);
}
--- 1957,1965 ----
if (noexec)
fprintf (stderr, "APPEND %s\n", name);
else
! #ifdef STRICT
if ( !directory )
! #endif
if ( !update_freshen || (cmp == 0) )
append_one (fp, nafp, &hdr);
}
***************
*** 2041,2048 ****
#define O_BINARY 0
#endif
! copy_archive(src,dst)
! char *src,*dst;
{
int ih, oh;
unsigned chunk;
--- 2042,2048 ----
#define O_BINARY 0
#endif
! copy_archive(char *src, char *dst)
{
int ih, oh;
unsigned chunk;
More information about the Alt.sources.patches
mailing list