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
911511bd
Commit
911511bd
authored
Dec 11, 2006
by
Rémi Denis-Courmont
Browse files
- WTF?! Do not use non-existant vlc_closedir_wrapper
- Do not leak result from utf8_readdir (ALWAYS strdup'ed).
parent
65c24e0d
Changes
5
Hide whitespace changes
Inline
Side-by-side
modules/demux/mkv.cpp
View file @
911511bd
...
...
@@ -1547,9 +1547,9 @@ static int Open( vlc_object_t * p_this )
}
}
}
LocaleF
ree
(
psz_file
);
f
ree
(
psz_file
);
}
vlc_
closedir
_wrapper
(
p_src_dir
);
closedir
(
p_src_dir
);
}
}
...
...
modules/gui/ncurses.c
View file @
911511bd
...
...
@@ -1995,7 +1995,7 @@ static void ReadDir( intf_thread_t *p_intf )
qsort
(
p_sys
->
pp_dir_entries
,
p_sys
->
i_dir_entries
,
sizeof
(
struct
dir_entry_t
*
),
&
comp_dir_entries
);
vlc_
closedir
_wrapper
(
p_current_dir
);
closedir
(
p_current_dir
);
return
;
}
else
...
...
modules/misc/gnutls.c
View file @
911511bd
...
...
@@ -597,7 +597,7 @@ gnutls_Addx509Directory( vlc_object_t *p_this,
||
fstat
(
fd
,
&
st1
)
||
utf8_lstat
(
psz_dirname
,
&
st2
)
||
S_ISLNK
(
st2
.
st_mode
)
||
(
st1
.
st_ino
!=
st2
.
st_ino
)
)
{
vlc_
closedir
_wrapper
(
dir
);
closedir
(
dir
);
return
VLC_EGENERIC
;
}
}
...
...
@@ -619,7 +619,7 @@ gnutls_Addx509Directory( vlc_object_t *p_this,
gnutls_Addx509File
(
p_this
,
cred
,
path
,
b_priv
);
}
vlc_
closedir
_wrapper
(
dir
);
closedir
(
dir
);
return
VLC_SUCCESS
;
}
...
...
src/text/unicode.c
View file @
911511bd
...
...
@@ -436,7 +436,8 @@ int utf8_mkdir( const char *dirname )
*
* @param dirname UTF-8 representation of the directory name
*
* @return a pointer to the DIR struct. Use vlc_closedir_wrapper() once you are done.
* @return a pointer to the DIR struct. Release with closedir().
*/
DIR
*
utf8_opendir
(
const
char
*
dirname
)
{
#ifdef WIN32
...
...
@@ -531,7 +532,7 @@ int utf8_scandir( const char *dirname, char ***namelist,
tab
=
newtab
;
tab
[
num
++
]
=
entry
;
}
vlc_
closedir
_wrapper
(
dir
);
closedir
(
dir
);
if
(
compar
!=
NULL
)
qsort
(
tab
,
num
,
sizeof
(
tab
[
0
]
),
...
...
src/video_output/vout_intf.c
View file @
911511bd
...
...
@@ -637,7 +637,7 @@ int vout_Snapshot( vout_thread_t *p_vout, picture_t *p_pic )
char
*
psz_prefix
=
var_GetString
(
p_vout
,
"snapshot-prefix"
);
if
(
!
psz_prefix
)
psz_prefix
=
strdup
(
"vlcsnap-"
);
vlc_
closedir
_wrapper
(
path
);
closedir
(
path
);
if
(
var_GetBool
(
p_vout
,
"snapshot-sequential"
)
==
VLC_TRUE
)
{
int
i_num
=
var_GetInteger
(
p_vout
,
"snapshot-num"
);
...
...
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