Note that if the handle is opened with O_APPEND then the pwrite() offset
is ignored and the write appends.
Signed-off-by: Charles Manning <cdhmanning@gmail.com>
yaffsfs_SetError(-EINVAL);
totalWritten=-1;
} else if( h && obj){
yaffsfs_SetError(-EINVAL);
totalWritten=-1;
} else if( h && obj){
- if(isPwrite)
- startPos = offset;
if(h->append)
startPos = yaffs_GetObjectFileLength(obj);
if(h->append)
startPos = yaffs_GetObjectFileLength(obj);
+ else if(isPwrite)
+ startPos = offset;
else
startPos = h->position;
else
startPos = h->position;