comparison 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
comparison
equal deleted inserted replaced
1321:2535ea9d0a6f 1324:871698dd3669
1 /* $OpenBSD: atomicio.h,v 1.7 2006/03/25 22:22:42 djm Exp $ */
1 2
2 /* 3 /*
3 * Copied from OpenSSH 3.6.1p2, required for loginrec.c 4 * Copied from OpenSSH/OpenBSD, required for loginrec.c
4 *
5 * $OpenBSD: atomicio.h,v 1.4 2001/06/26 06:32:46 itojun Exp $
6 * 5 *
7 * Copyright (c) 1995,1999 Theo de Raadt. All rights reserved. 6 * Copyright (c) 1995,1999 Theo de Raadt. All rights reserved.
8 * All rights reserved. 7 * All rights reserved.
9 * 8 *
10 * Redistribution and use in source and binary forms, with or without 9 * Redistribution and use in source and binary forms, with or without
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
28 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 28 */
30 29
31 #include "includes.h" 30 /*
31 * Ensure all of data on socket comes through. f==read || f==vwrite
32 */
33 size_t atomicio(ssize_t (*)(int, void *, size_t), int, void *, size_t);
32 34
33 /* 35 #define vwrite (ssize_t (*)(int, void *, size_t))write
34 * Ensure all of data on socket comes through. f==read || f==write
35 */
36 ssize_t atomicio(ssize_t (*)(), int, void *, size_t);