diff options
| author | svn2git <svn2git@FreeBSD.org> | 1994-07-01 08:00:00 +0000 |
|---|---|---|
| committer | svn2git <svn2git@FreeBSD.org> | 1994-07-01 08:00:00 +0000 |
| commit | 5e0e9b99dc3fc0ecd49d929db0d57c784b66f481 (patch) | |
| tree | e779b5a6edddbb949b7990751b12d6f25304ba86 /usr.bin/vi/mem.h | |
| parent | a16f65c7d117419bd266c28a1901ef129a337569 (diff) | |
Diffstat (limited to 'usr.bin/vi/mem.h')
| -rw-r--r-- | usr.bin/vi/mem.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/usr.bin/vi/mem.h b/usr.bin/vi/mem.h index 0f8fac4b8f39..f604cbd0aeed 100644 --- a/usr.bin/vi/mem.h +++ b/usr.bin/vi/mem.h @@ -1,5 +1,5 @@ /*- - * Copyright (c) 1993 + * Copyright (c) 1993, 1994 * The Regents of the University of California. All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -30,7 +30,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)mem.h 8.2 (Berkeley) 12/19/93 + * @(#)mem.h 8.5 (Berkeley) 3/16/94 */ /* Increase the size of a malloc'd buffer. Two versions, one that @@ -163,4 +163,11 @@ msgq(sp, M_SYSERR, NULL); \ } +/* + * Versions of memmove(3) and memset(3) that use the size of the + * initial pointer to figure out how much memory to manipulate. + */ +#define MEMMOVE(p, t, len) memmove(p, t, (len) * sizeof(*(p))) +#define MEMSET(p, value, len) memset(p, value, (len) * sizeof(*(p))) + int binc __P((SCR *, void *, size_t *, size_t)); |
