fix build

git-svn-id: http://svn.openzap.org/svn/openzap/trunk@659 a93c3328-9c30-0410-af19-c9cd2b2d52af
This commit is contained in:
Michael Jerris 2009-02-10 20:31:47 +00:00
parent 2e24552fa5
commit d424569f34

View File

@ -9,7 +9,9 @@ struct helper {
zap_status_t my_write_sample(int16_t *buf, zap_size_t buflen, void *user_data)
{
struct helper *foo = (struct helper *) user_data;
write(foo->fd, buf, buflen * 2);
size_t len;
len = write(foo->fd, buf, buflen * 2);
if (!len) return ZAP_FAIL;
foo->wrote += buflen * 2;
return ZAP_SUCCESS;
}