projects
/
platform
/
upstream
/
gstreamer.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c3b0509
)
multiudpsink: Reset windows error code after getting corresponding error message.
author
Andoni Morales Alastruey
<amorales@flumotion.com>
Wed, 10 Mar 2010 18:51:28 +0000
(10:51 -0800)
committer
Michael Smith
<msmith@songbirdnest.com>
Wed, 10 Mar 2010 18:51:28 +0000
(10:51 -0800)
gst/udp/gstmultiudpsink.c
patch
|
blob
|
history
diff --git
a/gst/udp/gstmultiudpsink.c
b/gst/udp/gstmultiudpsink.c
index
e828b6a
..
ae7abfe
100644
(file)
--- a/
gst/udp/gstmultiudpsink.c
+++ b/
gst/udp/gstmultiudpsink.c
@@
-411,7
+411,12
@@
socket_last_error_message ()
if (FAILED (result)) {
return g_strdup ("failed to get error message from system");
} else {
- return g_convert ((gchar *) buf, -1, "UTF-16", "UTF-8", NULL, NULL, NULL);
+ gchar *res =
+ g_convert ((gchar *) buf, -1, "UTF-16", "UTF-8", NULL, NULL, NULL);
+ /* g_convert() internally calls windows functions which reset the
+ windows error code, so fix it up again like this */
+ WSASetLastError (errorcode);
+ return res;
}
#else
return g_strdup (g_strerror (errno));