| 500 | |
| 501 | #ifndef _WIN32 |
| 502 | static char *text_parent_directory(const char *path) { |
| 503 | const char *separator = strrchr(path, '/'); |
| 504 | if (!separator) { |
| 505 | return cbm_strdup("."); |
| 506 | } |
| 507 | if (separator == path) { |
| 508 | return cbm_strdup("/"); |
| 509 | } |
| 510 | return cbm_strndup(path, (size_t)(separator - path)); |
| 511 | } |
| 512 | #endif |
| 513 | |
| 514 | static int text_snapshot_matches_path(const char *path, const char *expected_data, |
no test coverage detected