Mercurial > dropbear
diff atomicio.h @ 1324:871698dd3669
Merge pull request #26 from fperrad/kill_kr
remove K&R old style code
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Fri, 18 Nov 2016 22:48:50 +0800 |
parents | 83d85b28b353 |
children |
line wrap: on
line diff
--- a/atomicio.h Thu Sep 15 21:43:57 2016 +0800 +++ b/atomicio.h Fri Nov 18 22:48:50 2016 +0800 @@ -1,8 +1,7 @@ +/* $OpenBSD: atomicio.h,v 1.7 2006/03/25 22:22:42 djm Exp $ */ /* - * Copied from OpenSSH 3.6.1p2, required for loginrec.c - * - * $OpenBSD: atomicio.h,v 1.4 2001/06/26 06:32:46 itojun Exp $ + * Copied from OpenSSH/OpenBSD, required for loginrec.c * * Copyright (c) 1995,1999 Theo de Raadt. All rights reserved. * All rights reserved. @@ -28,9 +27,9 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include "includes.h" +/* + * Ensure all of data on socket comes through. f==read || f==vwrite + */ +size_t atomicio(ssize_t (*)(int, void *, size_t), int, void *, size_t); -/* - * Ensure all of data on socket comes through. f==read || f==write - */ -ssize_t atomicio(ssize_t (*)(), int, void *, size_t); +#define vwrite (ssize_t (*)(int, void *, size_t))write