[svn r668] Fixed but to release hostname string when the local machine does not have hostname set
2 #include "gmyth-stream-client.h"
4 int main (int argc, char** argv)
6 GMythStreamClient *cli = NULL;
11 cli = gmyth_stream_client_new ();
12 if (!gmyth_stream_client_connect (cli, "127.0.0.1", 50000)) {
13 g_warning ("Fail to connect");
17 ret = gmyth_stream_client_open_stream (cli, "file:///tmp/dvb.mpg",
18 "mpeg", "mpeg1video", 400, 25,
19 "mp2", 192, 320, 240, "format=mpeg1");
21 //myth:///tmp/mpg/bad_day.mpg mpeg mpeg1video 400 25 mp2 192 320 240 format=mpeg1
24 g_printerr ("Fail to open stream");
28 g_debug ("Stream created");
29 g_debug ("Going to PLAY now...");
31 gint fd = gmyth_stream_client_play_stream (cli);
34 g_printerr ("Fail to play stream");
40 gmyth_stream_client_close_stream(cli);
41 gmyth_stream_client_disconnect(cli);