Write can be called without cookie (in the CreateSymlink() case for example).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30907 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz
2009-05-28 21:58:42 +00:00
parent 41b1980691
commit 5740b42f36
@@ -477,9 +477,11 @@ status_t
OverlayInode::Write(void *_cookie, off_t position, const void *buffer, OverlayInode::Write(void *_cookie, off_t position, const void *buffer,
size_t *length) size_t *length)
{ {
open_cookie *cookie = (open_cookie *)_cookie; if (_cookie != NULL) {
if (cookie->open_mode & O_APPEND) open_cookie *cookie = (open_cookie *)_cookie;
position = fStat.st_size; if (cookie->open_mode & O_APPEND)
position = fStat.st_size;
}
// find insertion point // find insertion point
write_buffer **link = &fWriteBuffers; write_buffer **link = &fWriteBuffers;