Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Steve Lhomme
VLC
Commits
13174567
Commit
13174567
authored
Nov 10, 2009
by
ivoire
Browse files
libxml: return NULL for pointers (not 0).
parent
d497debb
Changes
1
Hide whitespace changes
Inline
Side-by-side
modules/misc/xml/libxml.c
View file @
13174567
...
...
@@ -246,8 +246,7 @@ static char *ReaderName( xml_reader_t *p_reader )
const
xmlChar
*
psz_name
=
xmlTextReaderConstName
(
p_reader
->
p_sys
->
p_reader
);
if
(
psz_name
)
return
strdup
(
(
const
char
*
)
psz_name
);
else
return
0
;
return
psz_name
?
strdup
(
(
const
char
*
)
psz_name
)
:
NULL
;
}
static
char
*
ReaderValue
(
xml_reader_t
*
p_reader
)
...
...
@@ -255,8 +254,7 @@ static char *ReaderValue( xml_reader_t *p_reader )
const
xmlChar
*
psz_value
=
xmlTextReaderConstValue
(
p_reader
->
p_sys
->
p_reader
);
if
(
psz_value
)
return
strdup
(
(
const
char
*
)
psz_value
);
else
return
0
;
return
psz_value
?
strdup
(
(
const
char
*
)
psz_value
)
:
NULL
;
}
static
int
ReaderNextAttr
(
xml_reader_t
*
p_reader
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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