Skip to content

Commit d21165b

Browse files
morecheck
1 parent 9f6e8b4 commit d21165b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

ext/socket/credentials.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,7 @@ credentials_s_from_ancdata(int argc, VALUE *argv, VALUE klass)
203203
#if defined(SCM_CREDS)
204204
if (level == SOL_SOCKET && type == SCM_CREDS) {
205205
bool local_creds_enabled;
206+
#if defined(LOCAL_CREDS)
206207
if (!RB_NIL_OR_UNDEF_P(local_creds_enabled_arg)) {
207208
local_creds_enabled = RB_TEST(local_creds_enabled_arg);
208209
} else if (!RB_NIL_OR_UNDEF_P(socket_arg)) {
@@ -217,6 +218,9 @@ credentials_s_from_ancdata(int argc, VALUE *argv, VALUE klass)
217218
local_creds_enabled = true;
218219
#endif
219220
}
221+
#else
222+
local_creds_enabled = false;
223+
#endif
220224

221225
if (local_creds_enabled) {
222226
#if defined(HAVE_TYPE_STRUCT_SOCKCRED)

0 commit comments

Comments
 (0)