{"action":"closed","issue":{"url":"https://api.github.com/repos/luvit/luv/issues/153","labels_url":"https://api.github.com/repos/luvit/luv/issues/153/labels{/name}","comments_url":"https://api.github.com/repos/luvit/luv/issues/153/comments","events_url":"https://api.github.com/repos/luvit/luv/issues/153/events","html_url":"https://github.com/luvit/luv/issues/153","id":81685329,"number":153,"title":"uv.fs_lstat on Windows not returning sb.type == \"link\"","user":{"login":"brimworks","id":64138,"avatar_url":"https://avatars.githubusercontent.com/u/64138?v=3","gravatar_id":"","url":"https://api.github.com/users/brimworks","html_url":"https://github.com/brimworks","followers_url":"https://api.github.com/users/brimworks/followers","following_url":"https://api.github.com/users/brimworks/following{/other_user}","gists_url":"https://api.github.com/users/brimworks/gists{/gist_id}","starred_url":"https://api.github.com/users/brimworks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brimworks/subscriptions","organizations_url":"https://api.github.com/users/brimworks/orgs","repos_url":"https://api.github.com/users/brimworks/repos","events_url":"https://api.github.com/users/brimworks/events{/privacy}","received_events_url":"https://api.github.com/users/brimworks/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/luvit/luv/labels/in%20progress","name":"in progress","color":"ededed"}],"state":"closed","locked":false,"assignee":{"login":"rphillips","id":1963,"avatar_url":"https://avatars.githubusercontent.com/u/1963?v=3","gravatar_id":"","url":"https://api.github.com/users/rphillips","html_url":"https://github.com/rphillips","followers_url":"https://api.github.com/users/rphillips/followers","following_url":"https://api.github.com/users/rphillips/following{/other_user}","gists_url":"https://api.github.com/users/rphillips/gists{/gist_id}","starred_url":"https://api.github.com/users/rphillips/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rphillips/subscriptions","organizations_url":"https://api.github.com/users/rphillips/orgs","repos_url":"https://api.github.com/users/rphillips/repos","events_url":"https://api.github.com/users/rphillips/events{/privacy}","received_events_url":"https://api.github.com/users/rphillips/received_events","type":"User","site_admin":false},"milestone":null,"comments":1,"created_at":"2015-05-28T00:20:08Z","updated_at":"2015-06-03T18:41:14Z","closed_at":"2015-06-03T18:41:14Z","body":"```sb = uv.fs_lstat()``` was not returning ```sb.type == \"link\"``` on windows, instead it was returning ```nil```. After some investigation, I found out that ``./include/uv-win.h``` defines S_IFLNK and therefore the S_ISLNK() macro can be defined as such:\r\n\r\n```diff\r\ndiff --git a/src/luv.h b/src/luv.h\r\nindex c3217a1..db52d55 100644\r\n--- a/src/luv.h\r\n+++ b/src/luv.h\r\n@@ -33,7 +33,7 @@\r\n # define S_ISFIFO(x) (((x) & _S_IFMT) == _S_IFIFO)\r\n # define S_ISCHR(x)  (((x) & _S_IFMT) == _S_IFCHR)\r\n # define S_ISBLK(x)  0\r\n-# define S_ISLNK(x)  0\r\n+# define S_ISLNK(x)  (((x) & S_IFLNK) == S_IFLNK)\r\n # define S_ISSOCK(x) 0\r\n #else\r\n # include <unistd.h>\r\n```\r\n\r\nI've verified that this fixes the windows incompatibility issue."}}