Skip to content

Commit

Permalink
base: use of g_value_dup_string
Browse files Browse the repository at this point in the history
Use helper method to get string from GValue.
  • Loading branch information
Stéphane Cerveau committed Dec 18, 2019
1 parent f8dc428 commit 58e6f59
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion gst/tcp/gsttcpclientsink.c
Expand Up @@ -240,7 +240,7 @@ gst_tcp_client_sink_set_property (GObject * object, guint prop_id,
break;
}
g_free (tcpclientsink->host);
tcpclientsink->host = g_strdup (g_value_get_string (value));
tcpclientsink->host = g_value_dup_string (value);
break;
case PROP_PORT:
tcpclientsink->port = g_value_get_int (value);
Expand Down
2 changes: 1 addition & 1 deletion gst/tcp/gsttcpclientsrc.c
Expand Up @@ -332,7 +332,7 @@ gst_tcp_client_src_set_property (GObject * object, guint prop_id,
break;
}
g_free (tcpclientsrc->host);
tcpclientsrc->host = g_strdup (g_value_get_string (value));
tcpclientsrc->host = g_value_dup_string (value);
break;
case PROP_PORT:
tcpclientsrc->port = g_value_get_int (value);
Expand Down
2 changes: 1 addition & 1 deletion gst/tcp/gsttcpserversink.c
Expand Up @@ -246,7 +246,7 @@ gst_tcp_server_sink_set_property (GObject * object, guint prop_id,
break;
}
g_free (sink->host);
sink->host = g_strdup (g_value_get_string (value));
sink->host = g_value_dup_string (value);
break;
case PROP_PORT:
sink->server_port = g_value_get_int (value);
Expand Down
2 changes: 1 addition & 1 deletion gst/tcp/gsttcpserversrc.c
Expand Up @@ -344,7 +344,7 @@ gst_tcp_server_src_set_property (GObject * object, guint prop_id,
break;
}
g_free (tcpserversrc->host);
tcpserversrc->host = g_strdup (g_value_get_string (value));
tcpserversrc->host = g_value_dup_string (value);
break;
case PROP_PORT:
tcpserversrc->server_port = g_value_get_int (value);
Expand Down
2 changes: 1 addition & 1 deletion sys/xvimage/xvimagesink.c
Expand Up @@ -1594,7 +1594,7 @@ gst_xv_image_sink_set_property (GObject * object, guint prop_id,
break;
case PROP_DISPLAY:
g_free (xvimagesink->config.display_name);
xvimagesink->config.display_name = g_strdup (g_value_get_string (value));
xvimagesink->config.display_name = g_value_dup_string (value);
break;
case PROP_SYNCHRONOUS:
xvimagesink->synchronous = g_value_get_boolean (value);
Expand Down

0 comments on commit 58e6f59

Please sign in to comment.