- (bal) OpenBSD CVS Update
   - markus@cvs.openbsd.org 2001/01/01 14:52:49
     [scp.c]
     use shared fatal(); from stevesk@pobox.com
This commit is contained in:
Ben Lindstrom 2001-01-02 04:55:52 +00:00
parent 321ae73a1f
commit 88c33974b2
3 changed files with 9 additions and 16 deletions

View File

@ -1,3 +1,9 @@
20010102
- (bal) OpenBSD CVS Update
- markus@cvs.openbsd.org 2001/01/01 14:52:49
[scp.c]
use shared fatal(); from stevesk@pobox.com
20001231
- (bal) Reverted out of MAXHOSTNAMELEN. This should be set per OS.
for multiple reasons.

View File

@ -91,8 +91,8 @@ ssh$(EXEEXT): libopenbsd-compat.a libssh.a $(SSHOBJS)
sshd$(EXEEXT): libssh.a libopenbsd-compat.a $(SSHDOBJS)
$(LD) -o $@ $(SSHDOBJS) $(LDFLAGS) -lssh -lopenbsd-compat $(LIBS)
scp$(EXEEXT): libopenbsd-compat.a libssh.a scp.o
$(LD) -o $@ scp.o $(LDFLAGS) -lssh -lopenbsd-compat $(LIBS)
scp$(EXEEXT): libopenbsd-compat.a libssh.a scp.o log-client.o
$(LD) -o $@ scp.o log-client.o $(LDFLAGS) -lssh -lopenbsd-compat $(LIBS)
ssh-add$(EXEEXT): libopenbsd-compat.a libssh.a ssh-add.o log-client.o
$(LD) -o $@ ssh-add.o log-client.o $(LDFLAGS) -lssh -lopenbsd-compat $(LIBS)

15
scp.c
View File

@ -75,7 +75,7 @@
*/
#include "includes.h"
RCSID("$OpenBSD: scp.c,v 1.47 2000/12/19 23:17:57 markus Exp $");
RCSID("$OpenBSD: scp.c,v 1.48 2001/01/01 14:52:49 markus Exp $");
#include "ssh.h"
#include "xmalloc.h"
@ -198,19 +198,6 @@ do_cmd(char *host, char *remuser, char *cmd, int *fdin, int *fdout, int argc)
return 0;
}
void
fatal(const char *fmt,...)
{
va_list ap;
char buf[1024];
va_start(ap, fmt);
vsnprintf(buf, sizeof(buf), fmt, ap);
va_end(ap);
fprintf(stderr, "%s\n", buf);
exit(255);
}
typedef struct {
int cnt;
char *buf;