[svn r826] gmyth-ls and gmyth_query now considers db_port. Thanks to Bastien Nocera for his patch.
1.1 --- a/gmyth/samples/gmyth_ls.c Wed Aug 22 14:07:49 2007 +0100
1.2 +++ b/gmyth/samples/gmyth_ls.c Wed Aug 22 14:55:41 2007 +0100
1.3 @@ -42,6 +42,7 @@
1.4
1.5 gchar *host_ip = NULL;
1.6 gint host_port = 0;
1.7 + gint db_port = 0;
1.8 gboolean list_channels = FALSE;
1.9 gchar *username = NULL;
1.10 gchar *password = NULL;
1.11 @@ -59,13 +60,17 @@
1.12 "LIST_CHANNELS"},
1.13
1.14 {"username", 'u', 0, G_OPTION_ARG_STRING, &username,
1.15 - "Mysql database username. Default: mythtv" "Mysql user",
1.16 + "Mysql database username. Default: mythtv",
1.17 "MYSQL_USER"},
1.18
1.19 {"password", 'w', 0, G_OPTION_ARG_STRING, &password,
1.20 - "Mysql database password. Default: mythtv" "Mysql password",
1.21 + "Mysql database password. Default: mythtv",
1.22 "MYSQL_PASSWD"},
1.23
1.24 + {"db_port", 'P', 0, G_OPTION_ARG_STRING, &db_port,
1.25 + "Mysql database port. Default: 0",
1.26 + "MYSQL_PORT"},
1.27 +
1.28 {NULL}
1.29 };
1.30
2.1 --- a/gmyth/src/gmyth_query.c Wed Aug 22 14:07:49 2007 +0100
2.2 +++ b/gmyth/src/gmyth_query.c Wed Aug 22 14:55:41 2007 +0100
2.3 @@ -161,7 +161,9 @@
2.4 gmyth_query->backend_info->hostname,
2.5 gmyth_query->backend_info->username,
2.6 gmyth_query->backend_info->password,
2.7 - gmyth_query->backend_info->db_name, 0, NULL,
2.8 + gmyth_query->backend_info->db_name,
2.9 + gmyth_query->backend_info->db_port,
2.10 + NULL,
2.11 0) == NULL) {
2.12 gmyth_query_print_error(gmyth_query->conn,
2.13 "mysql_real_connect() failed");