mirror of
https://github.com/git/git.git
synced 2026-03-13 18:33:25 +01:00
Provide the missing S_ISLNK and S_IFLNK macros.
Even though the file systems on Windows do not support symbolic links, repositories can still contain information about symbolic links, which is interrogated at many occasions. Without the correct definitions S_ISLNK and S_IFLNK, symbolic link information in the repository is not recognized and treated as corruption.
This commit is contained in:
@@ -298,8 +298,8 @@ static inline int prefixcmp(const char *str, const char *prefix)
|
||||
// MinGW
|
||||
|
||||
#ifndef S_ISLNK
|
||||
#define S_ISLNK(x) 0
|
||||
#define S_IFLNK 0
|
||||
#define S_IFLNK 0120000 /* Symbolic link */
|
||||
#define S_ISLNK(x) (((x) & S_IFMT) == S_IFLNK)
|
||||
#endif
|
||||
|
||||
#ifndef S_ISGRP
|
||||
|
||||
Reference in New Issue
Block a user