fix unsafe bb_perror_msg(filename) calls

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko 2012-09-27 15:35:10 +02:00
parent 225cc1327a
commit 9371043698
2 changed files with 3 additions and 3 deletions

View File

@ -442,7 +442,7 @@ static bool do_statfs(const char *filename, const char *format)
: getfilecon(filename, &scontext) : getfilecon(filename, &scontext)
) < 0 ) < 0
) { ) {
bb_perror_msg(filename); bb_simple_perror_msg(filename);
return 0; return 0;
} }
} }
@ -555,7 +555,7 @@ static bool do_stat(const char *filename, const char *format)
: getfilecon(filename, &scontext) : getfilecon(filename, &scontext)
) < 0 ) < 0
) { ) {
bb_perror_msg(filename); bb_simple_perror_msg(filename);
return 0; return 0;
} }
} }

View File

@ -93,7 +93,7 @@ static int lsattr_dir_proc(const char *dir_name, struct dirent *de,
path = concat_path_file(dir_name, de->d_name); path = concat_path_file(dir_name, de->d_name);
if (lstat(path, &st) == -1) if (lstat(path, &st) == -1)
bb_perror_msg(path); bb_simple_perror_msg(path);
else { else {
if (de->d_name[0] != '.' || (flags & OPT_ALL)) { if (de->d_name[0] != '.' || (flags & OPT_ALL)) {
list_attributes(path); list_attributes(path);