| 112 | } |
| 113 | |
| 114 | static bool path_is_absolute(const char *path) { |
| 115 | if (!path || !path[0]) { |
| 116 | return false; |
| 117 | } |
| 118 | if (path[0] == '/') { |
| 119 | return true; |
| 120 | } |
| 121 | #ifdef _WIN32 |
| 122 | return isalpha((unsigned char)path[0]) && path[1] == ':'; |
| 123 | #else |
| 124 | return false; |
| 125 | #endif |
| 126 | } |
| 127 | |
| 128 | static char *join_root_relative(const char *root, const char *rel) { |
| 129 | if (!root || !root[0]) { |
no outgoing calls
no test coverage detected