From 6c31adf67e5db7fe87d87d82d83d0de5c72ca484 Mon Sep 17 00:00:00 2001 From: Jeff Johnston Date: Mon, 5 May 2008 22:43:47 +0000 Subject: [PATCH] 2008-05-05 Ken Werner * spu/readlink.c: Align readlink implementation to POSIX. --- libgloss/ChangeLog | 4 ++++ libgloss/spu/readlink.c | 10 ++-------- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/libgloss/ChangeLog b/libgloss/ChangeLog index aa1f44508..51464386a 100644 --- a/libgloss/ChangeLog +++ b/libgloss/ChangeLog @@ -1,3 +1,7 @@ +2008-05-05 Ken Werner + + * spu/readlink.c: Align readlink implementation to POSIX. + 2008-04-25 Nick Clifton * arm/crt0.S: Allow assembly under ARMv7 ISA. Support for diff --git a/libgloss/spu/readlink.c b/libgloss/spu/readlink.c index ac7c59182..7a3dc9543 100644 --- a/libgloss/spu/readlink.c +++ b/libgloss/spu/readlink.c @@ -44,14 +44,8 @@ typedef struct unsigned int pad2[3]; } syscall_readlink_t; -/* - * POSIX says readlink returns ssize_t, and has an size_t bufsiz, but - * newlib has it prototyped as returning int, and int bufsiz. ssize_t, - * size_t and int are ally currently 4 bytes for SPU, so just leave them - * as ints for now. - */ -int -readlink (const char *path, char *buf, int bufsiz) +ssize_t +readlink (const char *path, char *buf, size_t bufsiz) { syscall_readlink_t sys;