Applied patch from Gregory Kovriga <gkovriga@techunix.technion.ac.il>

- Url was not properly parsed if an @ was in the file path.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7331 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
bertrand 2002-09-09 04:16:16 +00:00
parent cd8540ab8c
commit 75ed70c865
1 changed files with 5 additions and 0 deletions

View File

@ -57,6 +57,11 @@ url_new(char* url) {
// check if a username:password is given
ptr2 = strstr(ptr1, "@");
ptr3 = strstr(ptr1, "/");
if( ptr3!=NULL && ptr3<ptr2 ) {
// it isn't really a username but rather a part of the path
ptr2 = NULL;
}
if( ptr2!=NULL ) {
// We got something, at least a username...
int len = ptr2-ptr1;