[telepathy-gabble/master] Use g_error_new instead of g_set_error.
Mike Ruprecht
mike.ruprecht at collabora.co.uk
Tue Dec 29 05:35:09 PST 2009
This avoids GError complaining if *err is non-NULL and I'm not using an
existing GError, so it really is a new one.
---
src/call-stream-endpoint.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/src/call-stream-endpoint.c b/src/call-stream-endpoint.c
index d6fe6c7..24cc84b 100644
--- a/src/call-stream-endpoint.c
+++ b/src/call-stream-endpoint.c
@@ -332,8 +332,7 @@ call_stream_endpoint_set_stream_state (GabbleSvcCallStreamEndpoint *iface,
if (state >= NUM_TP_MEDIA_STREAM_STATES)
{
- GError *error;
- g_set_error (&error, TP_ERRORS, TP_ERROR_INVALID_ARGUMENT,
+ GError *error = g_error_new (TP_ERRORS, TP_ERROR_INVALID_ARGUMENT,
"Stream state is out of the valid range.");
dbus_g_method_return_error (context, error);
g_error_free (error);
--
1.5.6.5
More information about the telepathy-commits
mailing list