summaryrefslogtreecommitdiff
path: root/libav
diff options
context:
space:
mode:
authorFabrice Bellard <fabrice@bellard.org>2001-08-15 22:33:03 +0000
committerFabrice Bellard <fabrice@bellard.org>2001-08-15 22:33:03 +0000
commita74127c071fd46cdd40b9beca6721a9ca6338142 (patch)
treece84b21312cf30edc838cd5fbfba62ac21912b9b /libav
parentd0a0b2483e7b62e0f72c3b60f0a5f24175d665ee (diff)
win32 fixes
Originally committed as revision 110 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libav')
-rw-r--r--libav/Makefile6
-rw-r--r--libav/avio.c5
2 files changed, 8 insertions, 3 deletions
diff --git a/libav/Makefile b/libav/Makefile
index 80dfd389c9..17e4469114 100644
--- a/libav/Makefile
+++ b/libav/Makefile
@@ -4,12 +4,16 @@ CFLAGS= $(OPTFLAGS) -Wall -g -I../libavcodec -DHAVE_AV_CONFIG_H
OBJS= rm.o mpeg.o asf.o avienc.o jpeg.o swf.o wav.o raw.o \
avidec.o ffm.o \
avio.o aviobuf.o utils.o \
- udp.o http.o file.o img.o
+ file.o img.o
ifeq ($(CONFIG_GRAB),yes)
OBJS+= grab.o audio.o
endif
+ifneq ($(CONFIG_WIN32),yes)
+OBJS+= udp.o http.o
+endif
+
LIB= libav.a
all: $(LIB)
diff --git a/libav/avio.c b/libav/avio.c
index 5e16456a80..c3d9961db7 100644
--- a/libav/avio.c
+++ b/libav/avio.c
@@ -45,7 +45,8 @@ int url_open(URLContext **puc, const char *filename, int flags)
*q++ = *p;
p++;
}
- if (*p == '\0') {
+ /* if the protocol has length 1, we consider it is a dos drive */
+ if (*p == '\0' || (q - proto_str) <= 1) {
strcpy(proto_str, "file");
} else {
*q = '\0';
@@ -53,7 +54,7 @@ int url_open(URLContext **puc, const char *filename, int flags)
up = first_protocol;
while (up != NULL) {
- if (!strcmp(proto_str, up->name))
+ if (!strcmp(proto_str, up->name))
goto found;
up = up->next;
}