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
ff6e9662
Commit
ff6e9662
authored
Jul 22, 2015
by
Hugo Beauzée-Luyssen
Committed by
Jean-Baptiste Kempf
Jul 28, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
subsdec: Fix unicode regression
parent
948aa6c7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
modules/codec/subsdec.c
modules/codec/subsdec.c
+12
-2
No files found.
modules/codec/subsdec.c
View file @
ff6e9662
...
...
@@ -645,7 +645,17 @@ static subpicture_t *ParseText( decoder_t *p_dec, block_t *p_block )
return
p_spu
;
}
static
bool
AppendCharacter
(
text_segment_t
*
p_segment
,
wchar_t
c
)
static
bool
AppendCharacter
(
text_segment_t
*
p_segment
,
char
c
)
{
char
*
tmp
;
if
(
asprintf
(
&
tmp
,
"%s%c"
,
p_segment
->
psz_text
?
p_segment
->
psz_text
:
""
,
c
)
<
0
)
return
false
;
free
(
p_segment
->
psz_text
);
p_segment
->
psz_text
=
tmp
;
return
true
;
}
static
bool
AppendWideCharacter
(
text_segment_t
*
p_segment
,
wchar_t
c
)
{
char
*
tmp
;
if
(
asprintf
(
&
tmp
,
"%s%lc"
,
p_segment
->
psz_text
?
p_segment
->
psz_text
:
""
,
c
)
<
0
)
...
...
@@ -1154,7 +1164,7 @@ static text_segment_t* ParseSubtitles( int *pi_align, const char *psz_subtitle )
}
else
if
(
!
strncasecmp
(
psz_subtitle
,
"
\\
h"
,
2
)
)
{
if
(
!
AppendCharacter
(
p_segment
,
L
'\
u00A0
'
)
)
if
(
!
Append
Wide
Character
(
p_segment
,
L
'\
u00A0
'
)
)
goto
fail
;
psz_subtitle
+=
2
;
}
...
...
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