Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix darwin ci test #272

Merged
merged 2 commits into from
Jan 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,7 @@ jobs:
- run:
name: Test
command: |
# TODO: blocked by issue #236
# bash ./check.bash darwin
bash ./check.bash darwin
- run:
name: Build using autotools
command: |
Expand All @@ -99,6 +98,7 @@ jobs:
./configure
make
make install
make check

# Invoke jobs via workflows
# See: https://circleci.com/docs/2.0/configuration-reference/#workflows
Expand Down
14 changes: 9 additions & 5 deletions tests/LTsock.c
Original file line number Diff line number Diff line change
Expand Up @@ -261,11 +261,15 @@ main(argc, argv)
}
hnm[sizeof(hnm) - 1] = '\0';
if (!(hp = gethostbyname(hnm))) {
(void) snprintf(buf, bufl - 1, "ERROR!!! can't get IP address for %s",
hnm);
buf[bufl - 1] = '\0';
cem = buf;
goto print_errno;
// fallback to localhost if hostname cannot be resolved
strcpy(hnm, "localhost");
if (!(hp = gethostbyname(hnm))) {
(void) snprintf(buf, bufl - 1, "ERROR!!! can't get IP address for %s",
hnm);
buf[bufl - 1] = '\0';
cem = buf;
goto print_errno;
}
}
(void) memset((void *)&Myad, 0, sizeof(Myad));
if ((ti = hp->h_length) > sizeof(Myad.sin_addr))
Expand Down
1 change: 1 addition & 0 deletions tests/TestDB
Original file line number Diff line number Diff line change
Expand Up @@ -145,3 +145,4 @@ LT_BIGF LT_CC LT_DEV64 LT_DIAL_freebsd LT_KMEM LT_VERS=13000
LT_BIGF LT_CC LT_DIAL_linux LT_VERS=50009 _FILE_OFFSET_BITS=64
LT_BIGF LT_CC LT_DIAL_linux LT_VERS=60005 _FILE_OFFSET_BITS=64
LT_CC LT_DIAL_darwin LT_VERS=1900
LT_BIGF LT_CC LT_DIAL_darwin LT_VERS=1900