updated on Mon Jan 16 20:00:43 UTC 2012
[aur-mirror.git] / mms_client / mmsclient-0.0.3-r1.patch
blob44577643b3a8c73a0f74b5d44605d7d95898dc1e
1 diff -u mms_client-0.0.3/Makefile.in mms_client-0.0.4/Makefile.in
2 --- mms_client-0.0.3/Makefile.in 2002-01-21 18:51:31.000000000 -0800
3 +++ mms_client-0.0.4/Makefile.in 2004-04-17 15:57:10.241509408 -0700
4 @@ -85,7 +85,7 @@
5 mmsclient_DEPENDENCIES =
6 mmsclient_LDFLAGS =
7 CFLAGS = @CFLAGS@
8 -COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
9 +COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) "-DVERSION=\"$(VERSION)\""
10 CCLD = $(CC)
11 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS) -o $@
12 HEADERS = $(noinst_HEADERS)
13 diff -u mms_client-0.0.3/README mms_client-0.0.4/README
14 --- mms_client-0.0.3/README 2001-10-09 16:09:36.000000000 -0700
15 +++ mms_client-0.0.4/README 2004-04-17 17:16:29.204037136 -0700
16 @@ -0,0 +1,2 @@
17 +mmsclient downloads MMS (Microsoft Media Server) streams, and
18 +saves them to disk.
19 diff -u mms_client-0.0.3/client.c mms_client-0.0.4/client.c
20 --- mms_client-0.0.3/client.c 2001-12-28 19:40:48.000000000 -0800
21 +++ mms_client-0.0.4/client.c 2004-04-17 17:02:06.409201888 -0700
22 @@ -5,6 +5,9 @@
23 * mms://193.159.244.12/n24_wmt_mid
26 +#define HELPINFO "Usage: mmsclient mms://<url>\n -v --version\n\tPrint version information\n -h --help\n\tPrint this page\nhttp://www.geocities.com/majormms/\n"
29 #include <unistd.h>
30 #include <stdio.h>
31 #include <assert.h>
32 @@ -475,23 +478,44 @@
33 char *path, *url, *file, *cp;
35 if (argc != 2) {
36 - printf ("usage: %s url\n", argv[0]);
37 + printf ("Usage: %s URL\n", argv[0]);
38 exit(1);
42 + /* check for non-url arguments (version or help ...) */
43 + if (strncmp(argv[1], "mms://", 6) == 0 && argv[1][6] == 0){ /* Just typed "mms://" with no URL */
44 + printf("Error: No URL\n");
45 + exit(1);
46 + }
47 + if (strncmp(argv[1], "mms://", 6) != 0){ /* haven't typed a url */
49 + if (strncmp(argv[1], "--version", 9) == 0 || strncmp(argv[1], "-v", 9) == 0){
50 + printf("%s\n", VERSION);
51 + }else if (strncmp(argv[1], "--help", 9) == 0 || strncmp(argv[1], "-h", 9) == 0){
52 + printf("%s\n", HELPINFO);
53 + }else{
54 + printf("Error: unrecognized command %s\n", argv[1]);
55 + }
56 + exit(1);
57 + }
59 /* parse url */
61 url = argv[1];
62 strncpy (host, &url[6], 255);
63 cp = strchr(host,'/');
64 - *cp= 0;
65 + if(cp == 0){ /* If they just typed a top level domain name */
66 + printf("Error: Incomplete URL '%s'\n", &url[6]);
67 + exit(1);
68 + }
69 + *cp= 0; /* Make the '/' a null */
71 printf ("host : >%s<\n", host);
73 path = strchr(&url[6], '/') +1;
75 printf ("path : >%s<\n", path);
78 file = strrchr (url, '/');
80 printf ("file : >%s<\n", file);
81 diff -u mms_client-0.0.3/configure mms_client-0.0.4/configure
82 --- mms_client-0.0.3/configure 2002-01-21 18:50:51.000000000 -0800
83 +++ mms_client-0.0.4/configure 2004-04-17 16:47:01.126825728 -0700
84 @@ -694,7 +694,7 @@
86 PACKAGE="mms_client"
88 -VERSION=0.0.3
89 +VERSION=0.0.4
91 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
92 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }