Commit bd3c344f authored by Michael Meeks's avatar Michael Meeks Committed by Michael Meeks
Browse files

update for new bonobo code; why is this code duplicated here in a worse

2000-07-04  Michael Meeks  <michael@helixcode.com>

	* libnautilus-extensions/bonobo-stream-vfs.c (vfs_read): update
	for new bonobo code; why is this code duplicated here in a worse
	condition to that in Bonobo/storage-modules ?
parent 414d5358
2000-07-04 Michael Meeks <michael@helixcode.com>
* libnautilus-extensions/bonobo-stream-vfs.c (vfs_read): update
for new bonobo code; why is this code duplicated here in a worse
condition to that in Bonobo/storage-modules ?
2000-07-04 J Shane Culpepper <pepper@eazel.com>
* components/services/startup/nautilus-view/icons/Makefile.am:
*
components/services/startup/nautilus-view/nautilus-service-startup-
view.c: (generate_startup_form), (progress_timeout_cb),
(go_to_uri), (generate_form_title):
......
......@@ -51,10 +51,10 @@ vfs_write (BonoboStream *stream, const Bonobo_Stream_iobuf *buffer,
return written;
}
static CORBA_long
static void
vfs_read (BonoboStream *stream, CORBA_long count,
Bonobo_Stream_iobuf ** buffer,
CORBA_Environment *ev)
Bonobo_Stream_iobuf ** buffer,
CORBA_Environment *ev)
{
BonoboStreamVFS *sfs = BONOBO_STREAM_VFS (stream);
CORBA_octet *data;
......@@ -70,11 +70,14 @@ vfs_read (BonoboStream *stream, CORBA_long count,
if (res == GNOME_VFS_OK){
(*buffer)->_buffer = data;
(*buffer)->_length = nread;
} else
} else {
CORBA_free (data);
CORBA_free (*buffer);
*buffer = NULL;
CORBA_exception_set (ev, CORBA_USER_EXCEPTION,
ex_Bonobo_Stream_IOError, NULL);
}
sfs->got_eof = (res == GNOME_VFS_ERROR_EOF);
return nread;
}
static CORBA_long
......
......@@ -51,10 +51,10 @@ vfs_write (BonoboStream *stream, const Bonobo_Stream_iobuf *buffer,
return written;
}
static CORBA_long
static void
vfs_read (BonoboStream *stream, CORBA_long count,
Bonobo_Stream_iobuf ** buffer,
CORBA_Environment *ev)
Bonobo_Stream_iobuf ** buffer,
CORBA_Environment *ev)
{
BonoboStreamVFS *sfs = BONOBO_STREAM_VFS (stream);
CORBA_octet *data;
......@@ -70,11 +70,14 @@ vfs_read (BonoboStream *stream, CORBA_long count,
if (res == GNOME_VFS_OK){
(*buffer)->_buffer = data;
(*buffer)->_length = nread;
} else
} else {
CORBA_free (data);
CORBA_free (*buffer);
*buffer = NULL;
CORBA_exception_set (ev, CORBA_USER_EXCEPTION,
ex_Bonobo_Stream_IOError, NULL);
}
sfs->got_eof = (res == GNOME_VFS_ERROR_EOF);
return nread;
}
static CORBA_long
......
......@@ -51,10 +51,10 @@ vfs_write (BonoboStream *stream, const Bonobo_Stream_iobuf *buffer,
return written;
}
static CORBA_long
static void
vfs_read (BonoboStream *stream, CORBA_long count,
Bonobo_Stream_iobuf ** buffer,
CORBA_Environment *ev)
Bonobo_Stream_iobuf ** buffer,
CORBA_Environment *ev)
{
BonoboStreamVFS *sfs = BONOBO_STREAM_VFS (stream);
CORBA_octet *data;
......@@ -70,11 +70,14 @@ vfs_read (BonoboStream *stream, CORBA_long count,
if (res == GNOME_VFS_OK){
(*buffer)->_buffer = data;
(*buffer)->_length = nread;
} else
} else {
CORBA_free (data);
CORBA_free (*buffer);
*buffer = NULL;
CORBA_exception_set (ev, CORBA_USER_EXCEPTION,
ex_Bonobo_Stream_IOError, NULL);
}
sfs->got_eof = (res == GNOME_VFS_ERROR_EOF);
return nread;
}
static CORBA_long
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment