* becomes possible to allocate a new buffer.
*
* Return value: the new buffer (or %NULL)
+ *
+ * Deprecated: Use #SoupRequest if you want to read into your
+ * own buffers.
**/
/**
* destroyed
*
* Sets an alternate chunk-allocation function to use when reading
- * @msg's body. Every time data is available to read, libsoup will
- * call @allocator, which should return a #SoupBuffer. (See
+ * @msg's body when using the traditional (ie, non-#SoupRequest-based)
+ * API. Every time data is available to read, libsoup will call
+ * @allocator, which should return a #SoupBuffer. (See
* #SoupChunkAllocator for additional details.) Libsoup will then read
* data from the network into that buffer, and update the buffer's
* <literal>length</literal> to indicate how much data it read.
* you'll need to ref the #SoupBuffer (or its owner, in the
* soup_buffer_new_with_owner() case) to ensure that the data remains
* valid.
+ *
+ * Deprecated: #SoupRequest provides a much simpler API that lets you
+ * read the response directly into your own buffers without needing to
+ * mess with callbacks, pausing/unpausing, etc.
**/
void
soup_message_set_chunk_allocator (SoupMessage *msg,
msg = soup_message_new_from_uri ("GET", base_uri);
soup_message_body_set_accumulate (msg->response_body, FALSE);
+ G_GNUC_BEGIN_IGNORE_DEPRECATIONS;
soup_message_set_chunk_allocator (msg, chunk_allocator, >d, NULL);
+ G_GNUC_END_IGNORE_DEPRECATIONS;
g_signal_connect (msg, "got_chunk",
G_CALLBACK (got_chunk), >d);
soup_session_send_message (session, msg);