mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-06 02:50:43 +00:00
perf data: Correctly identify directory data files
In order to rename the "header" file to "data" without conflicting, correctly identify the non-header files as starting with "data." Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Reviewed-by: Jiri Olsa <jolsa@kernel.org> Link: http://lore.kernel.org/lkml/20191004083121.12182-2-adrian.hunter@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
d44f821b0e
commit
490e6db09a
1 changed files with 1 additions and 1 deletions
|
@ -96,7 +96,7 @@ int perf_data__open_dir(struct perf_data *data)
|
|||
if (stat(path, &st))
|
||||
continue;
|
||||
|
||||
if (!S_ISREG(st.st_mode) || strncmp(dent->d_name, "data", 4))
|
||||
if (!S_ISREG(st.st_mode) || strncmp(dent->d_name, "data.", 5))
|
||||
continue;
|
||||
|
||||
ret = -ENOMEM;
|
||||
|
|
Loading…
Reference in a new issue