diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2023-07-13 00:34:45 +0900 |
---|---|---|
committer | git <svn-admin@ruby-lang.org> | 2023-07-12 16:22:54 +0000 |
commit | 47cb789332e80d51699ab95ef610a69f5556d44d (patch) | |
tree | 43afc702a48993a77faf22c85ccd204a72cb13dd /ext | |
parent | f4bf80623fe72295cfa4a64de38a062d81359643 (diff) | |
download | ruby-47cb789332e80d51699ab95ef610a69f5556d44d.tar.gz |
[ruby/etc] Declare `getlogin` even if unistd.h is not available
Although MinGW provides this header but not the function, Windows
version ruby provides the function.
https://github.com/ruby/etc/commit/f7fa1884fa
Diffstat (limited to 'ext')
-rw-r--r-- | ext/etc/etc.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/ext/etc/etc.c b/ext/etc/etc.c index cf969038ff..78657b43d0 100644 --- a/ext/etc/etc.c +++ b/ext/etc/etc.c @@ -14,8 +14,6 @@ #include <sys/types.h> #ifdef HAVE_UNISTD_H #include <unistd.h> -#else -char *getlogin(void); #endif #ifdef HAVE_GETPWENT @@ -56,6 +54,7 @@ static VALUE sGroup; # include <stdlib.h> # endif #endif +char *getlogin(void); #define RUBY_ETC_VERSION "1.4.2" |