diff options
| author | Ulf Hermann <[email protected]> | 2017-04-06 15:14:09 +0200 |
|---|---|---|
| committer | Ulf Hermann <[email protected]> | 2017-05-08 09:45:39 +0000 |
| commit | e5cde7378c246a32d7dbc3bff8db15befad8b1a9 (patch) | |
| tree | 7586f1b4901236f1dbe28e022d6a4c9b84bef74e /libdwfl/linux-kernel-modules.c | |
| parent | 037d971fa81644af1d3be30db409309155fda721 (diff) | |
Use OS-specific paths
In general we need to use ';' as path separator and '\' and directory
separator on windows. The shell will automatically translate paths to
some extent, but we have to call "pwd -W" rather than plain "pwd" to
get something useful.
Change-Id: I1a117d219a2aa00c1f77ae7d3a1d92b9bae526db
Reviewed-by: Christian Kandeler <[email protected]>
Diffstat (limited to 'libdwfl/linux-kernel-modules.c')
| -rw-r--r-- | libdwfl/linux-kernel-modules.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libdwfl/linux-kernel-modules.c b/libdwfl/linux-kernel-modules.c index 139a4774..bd963d32 100644 --- a/libdwfl/linux-kernel-modules.c +++ b/libdwfl/linux-kernel-modules.c @@ -48,6 +48,7 @@ #include <sys/utsname.h> #include <fcntl.h> #include <unistd.h> +#include <system.h> /* If fts.h is included before config.h, its indirect inclusions may not give us the right LFS aliases of these functions, so map them manually. */ @@ -96,7 +97,7 @@ try_kernel_name (Dwfl *dwfl, char **fname, bool try_debug) tried because we give its own basename as DEBUGLINK_FILE. */ int fd = ((((dwfl->callbacks->debuginfo_path ? *dwfl->callbacks->debuginfo_path : NULL) - ?: DEFAULT_DEBUGINFO_PATH)[0] == ':') ? -1 + ?: DEFAULT_DEBUGINFO_PATH)[0] == PATHSEP) ? -1 : TEMP_FAILURE_RETRY (open (*fname, O_RDONLY | O_BINARY))); if (fd < 0) |
