diff options
| author | Paul Pogonyshev <pogonyshev@gmx.net> | 2008-12-21 16:08:01 +0000 |
|---|---|---|
| committer | Paul Pogonyshev <paulp@src.gnome.org> | 2008-12-21 16:08:01 +0000 |
| commit | a1b44acabfbca2fd6931699a9407fe8f9d95d253 (patch) | |
| tree | 34ee13f3903add4b34ee9499cf1d05d7e0e9f620 /gio/gfile.override | |
| parent | 95886775af564a05aaaf5708f0b37279f82d0d76 (diff) | |
| download | pygobject-a1b44acabfbca2fd6931699a9407fe8f9d95d253.tar.gz pygobject-a1b44acabfbca2fd6931699a9407fe8f9d95d253.tar.xz pygobject-a1b44acabfbca2fd6931699a9407fe8f9d95d253.zip | |
Merge from 2.16 branch:
2008-12-21 Paul Pogonyshev <pogonyshev@gmx.net>
Bug 564102 – _wrap_g_output_stream_write_async not adding a
reference to the buffer passed
* gio/gio.override (pygio_notify_copy_buffer): New function.
(pygio_free_notify): Free new `buffer' field if it is set.
* gio/goutputstream.override (_wrap_g_output_stream_write_async):
Copy the buffer with new pygio_notify_copy_buffer() and use the
copy for g_output_stream_write_async() call.
* gio/gfile.override (_wrap_g_file_replace_contents_async): Same
as for _wrap_g_output_stream_write_async().
svn path=/trunk/; revision=981
Diffstat (limited to 'gio/gfile.override')
| -rw-r--r-- | gio/gfile.override | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gio/gfile.override b/gio/gfile.override index 77dad6f..deb43e8 100644 --- a/gio/gfile.override +++ b/gio/gfile.override @@ -1110,9 +1110,10 @@ _wrap_g_file_replace_contents_async(PyGObject *self, PyObject *args, PyObject *k Py_INCREF(notify->callback); Py_XINCREF(notify->data); + pygio_notify_copy_buffer(notify, contents, length); g_file_replace_contents_async(G_FILE(self->obj), - contents, - length, + notify->buffer, + notify->buffer_size, etag, make_backup, flags, |
