Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
c51ce947
Commit
c51ce947
authored
Nov 27, 2006
by
Derk-Jan Hartman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* Fix mp4 relative ref. files (this was already fixed in trunk)
parent
e34e9d8c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
47 deletions
+29
-47
modules/demux/mp4/mp4.c
modules/demux/mp4/mp4.c
+29
-47
No files found.
modules/demux/mp4/mp4.c
View file @
c51ce947
...
@@ -368,7 +368,7 @@ static int Open( vlc_object_t * p_this )
...
@@ -368,7 +368,7 @@ static int Open( vlc_object_t * p_this )
char
*
psz_ref
;
char
*
psz_ref
;
uint32_t
i_ref_type
;
uint32_t
i_ref_type
;
if
(
!
p_rdrf
||
!
(
psz_ref
=
p_rdrf
->
data
.
p_rdrf
->
psz_ref
)
)
if
(
!
p_rdrf
||
!
(
psz_ref
=
strdup
(
p_rdrf
->
data
.
p_rdrf
->
psz_ref
)
)
)
{
{
continue
;
continue
;
}
}
...
@@ -387,48 +387,30 @@ static int Open( vlc_object_t * p_this )
...
@@ -387,48 +387,30 @@ static int Open( vlc_object_t * p_this )
if
(
!
strncmp
(
psz_ref
,
"http://"
,
7
)
||
if
(
!
strncmp
(
psz_ref
,
"http://"
,
7
)
||
!
strncmp
(
psz_ref
,
"rtsp://"
,
7
)
)
!
strncmp
(
psz_ref
,
"rtsp://"
,
7
)
)
{
{
msg_Dbg
(
p_demux
,
"adding ref = `%s'"
,
psz_ref
);
;
if
(
p_item
)
{
playlist_item_t
*
p_child
=
playlist_ItemNew
(
p_playlist
,
psz_ref
,
psz_ref
);
if
(
p_child
)
{
playlist_NodeAddItem
(
p_playlist
,
p_child
,
p_item
->
pp_parents
[
0
]
->
i_view
,
p_item
,
PLAYLIST_APPEND
,
PLAYLIST_END
);
playlist_CopyParents
(
p_item
,
p_child
);
b_play
=
VLC_TRUE
;
}
}
}
}
else
else
{
{
/* msg dbg relative ? */
char
*
psz_absolute
;
int
i_path_size
=
strlen
(
p_demux
->
psz_access
)
+
3
+
char
*
psz_path
=
strdup
(
p_demux
->
psz_path
);
strlen
(
p_demux
->
psz_path
)
+
strlen
(
psz_ref
)
+
1
;
char
*
end
=
strrchr
(
psz_path
,
'/'
);
char
psz_absolute
[
i_path_size
];
char
*
end
=
strrchr
(
p_demux
->
psz_path
,
'/'
);
if
(
end
)
if
(
end
)
end
[
1
]
=
'\0'
;
{
else
*
psz_path
=
'\0'
;
snprintf
(
psz_absolute
,
i_path_size
,
"%s://%s"
,
p_demux
->
psz_access
,
p_demux
->
psz_path
);
asprintf
(
&
psz_absolute
,
"%s://%s%s"
,
}
p_demux
->
psz_access
,
psz_path
,
psz_ref
);
else
{
if
(
psz_ref
)
free
(
psz_ref
);
*
psz_absolute
=
'\0'
;
psz_ref
=
psz_absolute
;
free
(
psz_path
);
}
}
strcat
(
psz_absolute
,
psz_ref
);
msg_Dbg
(
p_demux
,
"adding ref = `%s'"
,
psz_ref
);
msg_Dbg
(
p_demux
,
"adding ref = `%s'"
,
psz_absolute
);
if
(
p_item
)
if
(
p_item
)
{
{
playlist_item_t
*
p_child
=
playlist_item_t
*
p_child
=
playlist_ItemNew
(
p_playlist
,
playlist_ItemNew
(
p_playlist
,
psz_absolute
,
psz_ref
,
psz_ref
);
psz_absolute
);
if
(
p_child
)
if
(
p_child
)
{
{
playlist_NodeAddItem
(
p_playlist
,
p_child
,
playlist_NodeAddItem
(
p_playlist
,
p_child
,
...
@@ -440,12 +422,12 @@ static int Open( vlc_object_t * p_this )
...
@@ -440,12 +422,12 @@ static int Open( vlc_object_t * p_this )
}
}
}
}
}
}
}
else
else
{
{
msg_Err
(
p_demux
,
"unknown ref type=%4.4s FIXME (send a bug report)"
,
msg_Err
(
p_demux
,
"unknown ref type=%4.4s FIXME (send a bug report)"
,
(
char
*
)
&
p_rdrf
->
data
.
p_rdrf
->
i_ref_type
);
(
char
*
)
&
p_rdrf
->
data
.
p_rdrf
->
i_ref_type
);
}
}
if
(
psz_ref
)
free
(
psz_ref
);
}
}
if
(
b_play
==
VLC_TRUE
)
if
(
b_play
==
VLC_TRUE
)
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment