| 182 | } |
| 183 | |
| 184 | static bool changes_mode(changes_slice_t line, const char *prefix) { |
| 185 | size_t length = strlen(prefix); |
| 186 | if (line.length != length + 6) { |
| 187 | return false; |
| 188 | } |
| 189 | const unsigned char *mode = line.bytes + length; |
| 190 | return memcmp(mode, "100644", 6) == 0 || memcmp(mode, "100755", 6) == 0 || |
| 191 | memcmp(mode, "120000", 6) == 0 || memcmp(mode, "160000", 6) == 0; |
| 192 | } |
| 193 | |
| 194 | static bool changes_side_path(changes_slice_t line, const cbm_change_file_t *file, bool old) { |
| 195 | const unsigned char *bytes = line.bytes + 4; /* checked ---/+++ prefix */ |
no outgoing calls
no test coverage detected