diff options
author | Daniel Mierswa | 2009-08-17 07:27:39 +0200 |
---|---|---|
committer | Karel Zak | 2009-08-17 11:15:59 +0200 |
commit | c0f19ccff73aa0ec5e9f3b61b932ea4a8bf4e6ed (patch) | |
tree | 6d4671545542031f67face36783f8ad64b29057c /text-utils/colcrt.c | |
parent | libblkid: fix cache->probe memory leak (diff) | |
download | kernel-qcow2-util-linux-c0f19ccff73aa0ec5e9f3b61b932ea4a8bf4e6ed.tar.gz kernel-qcow2-util-linux-c0f19ccff73aa0ec5e9f3b61b932ea4a8bf4e6ed.tar.xz kernel-qcow2-util-linux-c0f19ccff73aa0ec5e9f3b61b932ea4a8bf4e6ed.zip |
replace bcopy,bzero,index and rindex
Those 4 functions are marked as LEGACY in POSIX.1-2001 and removed in
POSIX.1-2008.
Replaced with memmove,memset,strchr and strrchr.
Signed-off-by: Daniel Mierswa <impulze@impulze.org>
Diffstat (limited to 'text-utils/colcrt.c')
-rw-r--r-- | text-utils/colcrt.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/text-utils/colcrt.c b/text-utils/colcrt.c index 891fd86db..6f796656d 100644 --- a/text-utils/colcrt.c +++ b/text-utils/colcrt.c @@ -252,8 +252,8 @@ void pflush(int ol) } putwchar('\n'); } - bcopy(page[ol], page, (267 - ol) * 132 * sizeof(wchar_t)); - bzero(page[267- ol], ol * 132 * sizeof(wchar_t)); + memmove(page, page[ol], (267 - ol) * 132 * sizeof(wchar_t)); + memset(page[267- ol], '\0', ol * 132 * sizeof(wchar_t)); outline -= ol; outcol = 0; first = 1; |