[gupnp-tools] upload: Check for UDN
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gupnp-tools] upload: Check for UDN
- Date: Sun, 7 Jun 2020 16:05:50 +0000 (UTC)
commit 4da7a32c052b42785b748624a3002210bd9b19f5
Author: Jens Georg <mail jensge org>
Date: Sun Jun 7 18:05:18 2020 +0200
upload: Check for UDN
src/upload/main.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
---
diff --git a/src/upload/main.c b/src/upload/main.c
index 0b60f5a..a47cb1e 100644
--- a/src/upload/main.c
+++ b/src/upload/main.c
@@ -150,7 +150,7 @@ main (gint argc,
return -1;
}
- if (argc < 3) {
+ if (argc < 2) {
char *help = NULL;
help = g_option_context_get_help (context, TRUE, NULL);
@@ -160,6 +160,11 @@ main (gint argc,
return -4;
}
+ if (udn == NULL) {
+ g_print ("Error: Please provide UDN for the target server\n");
+ return -4;
+ }
+
/* Get the list of files to upload */
for (i = 1; i < argc; i++) {
if (!g_file_test (argv[i],
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]