putw.c (d1d015864103b253b3fcb2f72a0da5b0cfeb31b6) | putw.c (86727cc9c641d61be9930e7409e718bed1a553f7) |
---|---|
1/*- 2 * Copyright (c) 1990, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * Chris Torek. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 36 unchanged lines hidden (view full) --- 45int 46putw(int w, FILE *fp) 47{ 48 int retval; 49 struct __suio uio; 50 struct __siov iov; 51 52 iov.iov_base = &w; | 1/*- 2 * Copyright (c) 1990, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * Chris Torek. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 36 unchanged lines hidden (view full) --- 45int 46putw(int w, FILE *fp) 47{ 48 int retval; 49 struct __suio uio; 50 struct __siov iov; 51 52 iov.iov_base = &w; |
53 iov.iov_len = uio.uio_resid = sizeof(w); | 53 uio.uio_resid = iov.iov_len = sizeof(w); |
54 uio.uio_iov = &iov; 55 uio.uio_iovcnt = 1; 56 FLOCKFILE(fp); 57 retval = __sfvwrite(fp, &uio); 58 FUNLOCKFILE(fp); 59 return (retval); 60} | 54 uio.uio_iov = &iov; 55 uio.uio_iovcnt = 1; 56 FLOCKFILE(fp); 57 retval = __sfvwrite(fp, &uio); 58 FUNLOCKFILE(fp); 59 return (retval); 60} |