Commit 61619557
6161955724a9Merged
Yasuhiro Matsumoto <[email protected]> · 7 months ago · 1 file · ~1 modified
Description
fix(parser): use _fullpath on Windows where realpath is unavailable
Details
- Commit
- 6161955724a9
- Parent
- 913d8cd25cec
spinel_parse.cmodifiedView file
@@ -771,7 +771,11 @@
771771
/* Resolve a path to its canonical form for dedup. realpath() returns NULL772772
on missing files; in that case fall back to the literal path. */773773
static char *sp_canonical_path(const char *path) {774+
#ifdef _WIN32775+
char *real = _fullpath(NULL, path, 0);776+
#else774777
char *real = realpath(path, NULL);778+
#endif775779
return real ? real : strdup(path);776780
}777781