make use of xfree() consistent. from openbsd

This commit is contained in:
itojun 2002-07-01 05:56:45 +00:00
parent 11792b93b1
commit 84559971ee
4 changed files with 12 additions and 12 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: auth2-none.c,v 1.2 2002/06/24 05:48:27 itojun Exp $ */
/* $NetBSD: auth2-none.c,v 1.3 2002/07/01 05:56:45 itojun Exp $ */
/*
* Copyright (c) 2000 Markus Friedl. All rights reserved.
*
@ -24,7 +24,7 @@
*/
#include "includes.h"
RCSID("$OpenBSD: auth2-none.c,v 1.3 2002/06/19 00:27:55 deraadt Exp $");
RCSID("$OpenBSD: auth2-none.c,v 1.4 2002/06/27 10:35:47 deraadt Exp $");
#include "auth.h"
#include "xmalloc.h"
@ -62,7 +62,7 @@ auth2_read_banner(void)
close(fd);
if (n != len) {
free(banner);
xfree(banner);
return (NULL);
}
banner[n] = '\0';

View File

@ -1,4 +1,4 @@
/* $NetBSD: monitor.c,v 1.5 2002/06/26 14:08:31 itojun Exp $ */
/* $NetBSD: monitor.c,v 1.6 2002/07/01 05:56:45 itojun Exp $ */
/*
* Copyright 2002 Niels Provos <provos@citi.umich.edu>
* Copyright 2002 Markus Friedl <markus@openbsd.org>
@ -26,7 +26,7 @@
*/
#include "includes.h"
RCSID("$OpenBSD: monitor.c,v 1.18 2002/06/26 13:20:57 deraadt Exp $");
RCSID("$OpenBSD: monitor.c,v 1.21 2002/06/27 10:35:47 deraadt Exp $");
#include <openssl/dh.h>
@ -541,7 +541,7 @@ int mm_answer_auth2_read_banner(int socket, Buffer *m)
mm_request_send(socket, MONITOR_ANS_AUTH2_READ_BANNER, m);
if (banner != NULL)
free(banner);
xfree(banner);
return (0);
}

View File

@ -1,5 +1,5 @@
/* $NetBSD: session.h,v 1.3 2002/06/24 05:48:34 itojun Exp $ */
/* $OpenBSD: session.h,v 1.18 2002/06/23 21:06:41 deraadt Exp $ */
/* $NetBSD: session.h,v 1.4 2002/07/01 05:56:45 itojun Exp $ */
/* $OpenBSD: session.h,v 1.19 2002/06/30 21:59:45 deraadt Exp $ */
/*
* Copyright (c) 2000, 2001 Markus Friedl. All rights reserved.
@ -60,7 +60,7 @@ struct Session {
void do_authenticated(Authctxt *);
int session_open(Authctxt*, int);
int session_open(Authctxt *, int);
int session_input_channel_req(Channel *, const char *);
void session_close_by_pid(pid_t, int);
void session_close_by_channel(int, void *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: sftp-client.c,v 1.16 2002/06/24 05:48:34 itojun Exp $ */
/* $NetBSD: sftp-client.c,v 1.17 2002/07/01 05:56:45 itojun Exp $ */
/*
* Copyright (c) 2001,2002 Damien Miller. All rights reserved.
*
@ -29,7 +29,7 @@
/* XXX: copy between two remote sites */
#include "includes.h"
RCSID("$OpenBSD: sftp-client.c,v 1.33 2002/06/23 09:30:14 deraadt Exp $");
RCSID("$OpenBSD: sftp-client.c,v 1.34 2002/06/27 10:35:47 deraadt Exp $");
#include <sys/queue.h>
@ -1092,7 +1092,7 @@ do_upload(struct sftp_conn *conn, char *local_path, char *remote_path,
debug3("In write loop, ack for %u %u bytes at %llu",
ack->id, ack->len, (unsigned long long)ack->offset);
++ackid;
free(ack);
xfree(ack);
}
offset += len;
}