/* Returns: TRUE if @string was successfully added to the @stream.  */
gboolean g_data_output_stream_put_string(GDataOutputStream *stream, const char *str, GCancellable *cancellable, GError **error)
/* Returns: TRUE if @string was successfully added to the @stream.  */
gboolean g_data_output_stream_put_string(GDataOutputStream *stream, const char *str, GCancellable *cancellable, GError **error)
{
  gsize bytes_written;
  g_return_val_if_fail (G_IS_DATA_OUTPUT_STREAM (stream), FALSE);
  g_return_val_if_fail (str != NULL, FALSE);
  return g_output_stream_write_all (G_OUTPUT_STREAM (stream),
				    str, strlen (str),
				    &bytes_written,
				    cancellable, error);
}