Skip to content

Commit 26c2407

Browse files
committed
small stuff
1 parent eebff2d commit 26c2407

File tree

7 files changed

+26
-4
lines changed

7 files changed

+26
-4
lines changed

.github/workflows/c-cpp.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,17 @@ on:
88

99
jobs:
1010
build:
11+
strategy:
12+
fail-fast: false
1113

1214
runs-on: ubuntu-latest
1315
timeout-minutes: 20
1416

1517
steps:
1618
- uses: actions/checkout@v3
19+
- name: Setup ENV
20+
run: |
21+
echo "CI=false" >> "$GITHUB_ENV"
1722
- name: Test STL (debug) - no allocators
1823
run: CFLAGS="-DFIO_MEMORY_DISABLE -DFIO_MEMALT" make db/test
1924
- name: Test STL

.github/workflows/macos-c-cpp.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,17 @@ on:
88

99
jobs:
1010
build:
11+
strategy:
12+
fail-fast: false
1113

1214
runs-on: macos-latest
1315
timeout-minutes: 20
1416

1517
steps:
1618
- uses: actions/checkout@v3
19+
- name: Setup ENV
20+
run: |
21+
echo "CI=false" >> "$GITHUB_ENV"
1722
- name: Test STL (debug) - no allocators
1823
run: CFLAGS="-DFIO_MEMORY_DISABLE -DFIO_MEMALT" make db/test
1924
- name: Test STL

.github/workflows/windows.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,18 @@ on:
88

99
jobs:
1010
build:
11+
strategy:
12+
fail-fast: false
1113

1214
runs-on: windows-latest
1315
timeout-minutes: 20
1416

1517
steps:
1618
- uses: actions/checkout@v3
1719
- uses: ilammy/msvc-dev-cmd@v1
20+
- name: Setup ENV
21+
run: |
22+
echo "CI=false" >> "$GITHUB_ENV"
1823
- name: Test No-Op (debug)
1924
run: cl /Od /RTCsu /TC tests\noop.c /I. /D_CRT_NONSTDC_NO_WARNINGS /DFIO_LEAK_COUNTER=1 /DDEBUG /Fe./noop.exe && ./noop.exe
2025
- name: Test STL (debug) - no allocators

.github/workflows/windows_clang.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ on:
88

99
jobs:
1010
build:
11+
strategy:
12+
fail-fast: false
1113

1214
runs-on: windows-latest
1315
timeout-minutes: 30
@@ -17,6 +19,9 @@ jobs:
1719
- uses: egor-tensin/setup-clang@v1
1820
with:
1921
platform: x64
22+
- name: Setup ENV
23+
run: |
24+
echo "CI=false" >> "$GITHUB_ENV"
2025
- name: Test No-Op (debug)
2126
run: clang -O0 -fstack-protector-all tests\noop.c -I. -DFIO_LEAK_COUNTER=1 -DDEBUG -D_CRT_NONSTDC_NO_WARNINGS -o ./noop.exe && ./noop.exe
2227
- name: Test STL (debug) - no allocators

fio-stl.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20720,7 +20720,7 @@ SFUNC int fio_bstr_reallocate(fio_str_info_s *dest, size_t len) {
2072020720
size_t new_capa = fio_string_capa4len(len + sizeof(bstr_m[0]));
2072120721
if (FIO_UNLIKELY(new_capa > (size_t)0xFFFFFFFFULL))
2072220722
new_capa = (size_t)0x0FFFFFFFFULL + sizeof(bstr_m[0]);
20723-
if (dest->capa < fio_string_capa4len(sizeof(bstr_m[0])) - 1)
20723+
if (dest->capa < fio_string_capa4len(sizeof(bstr_m[0])))
2072420724
goto copy_the_string;
2072520725
bstr_m = (fio___bstr_meta_s *)FIO_MEM_REALLOC_(
2072620726
((fio___bstr_meta_s *)dest->buf - 1),
@@ -32895,7 +32895,8 @@ FIO_SFUNC void fio_s_init(fio_s *io) {
3289532895

3289632896
FIO_IFUNC void fio___s_monitor_in(fio_s *io) {
3289732897
if ((fio_atomic_or(&io->pflags, FIO___IO_STATE_POLLIN_SET) &
32898-
FIO___IO_STATE_POLLIN_SET) == FIO___IO_STATE_POLLIN_SET)
32898+
(FIO___IO_STATE_POLLIN_SET | FIO___IO_STATE_SUSPENDED |
32899+
FIO___IO_STATE_THROTTLED | FIO___IO_STATE_CLOSING)))
3289932900
return;
3290032901
fio_poll_monitor(&fio___srvdata.poll_data, io->fd, (void *)io, POLLIN);
3290132902
}

fio-stl/102 string core.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2747,7 +2747,7 @@ SFUNC int fio_bstr_reallocate(fio_str_info_s *dest, size_t len) {
27472747
size_t new_capa = fio_string_capa4len(len + sizeof(bstr_m[0]));
27482748
if (FIO_UNLIKELY(new_capa > (size_t)0xFFFFFFFFULL))
27492749
new_capa = (size_t)0x0FFFFFFFFULL + sizeof(bstr_m[0]);
2750-
if (dest->capa < fio_string_capa4len(sizeof(bstr_m[0])) - 1)
2750+
if (dest->capa < fio_string_capa4len(sizeof(bstr_m[0])))
27512751
goto copy_the_string;
27522752
bstr_m = (fio___bstr_meta_s *)FIO_MEM_REALLOC_(
27532753
((fio___bstr_meta_s *)dest->buf - 1),

fio-stl/400 server.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1285,7 +1285,8 @@ FIO_SFUNC void fio_s_init(fio_s *io) {
12851285

12861286
FIO_IFUNC void fio___s_monitor_in(fio_s *io) {
12871287
if ((fio_atomic_or(&io->pflags, FIO___IO_STATE_POLLIN_SET) &
1288-
FIO___IO_STATE_POLLIN_SET) == FIO___IO_STATE_POLLIN_SET)
1288+
(FIO___IO_STATE_POLLIN_SET | FIO___IO_STATE_SUSPENDED |
1289+
FIO___IO_STATE_THROTTLED | FIO___IO_STATE_CLOSING)))
12891290
return;
12901291
fio_poll_monitor(&fio___srvdata.poll_data, io->fd, (void *)io, POLLIN);
12911292
}

0 commit comments

Comments
 (0)