Compare commits

...

4 Commits

3 changed files with 8 additions and 8 deletions

View File

@@ -10,8 +10,8 @@ jobs:
os: os:
- ubuntu-latest - ubuntu-latest
- ubuntu-24.04-arm - ubuntu-24.04-arm
- windows-latest # - windows-latest
- windows-11-arm # - windows-11-arm
- macos-latest - macos-latest
runs-on: ${{matrix.os}} runs-on: ${{matrix.os}}
steps: steps:
@@ -32,6 +32,6 @@ jobs:
path: lib/obj/ path: lib/obj/
key: ${{runner.os}}-lib/obj-${{github.sha}} key: ${{runner.os}}-lib/obj-${{github.sha}}
restore-keys: ${{runner.os}}-lib/obj- restore-keys: ${{runner.os}}-lib/obj-
- run: make libs - run: make -j libs
- run: make all - run: make -j all
- run: make test - run: make -j test

View File

@@ -10,7 +10,7 @@ LD ?= ld
# setting default compilation flags # setting default compilation flags
# some of which are able to be overwritten, others are always appended # some of which are able to be overwritten, others are always appended
CPPFLAGS ?= CPPFLAGS ?=
CFLAGS ?= -O2 -Wall -Wextra -Wpedantic CFLAGS ?= -O2 -Wall -Wextra -Wpedantic -Wno-pointer-arith
LDFLAGS ?= -flto LDFLAGS ?= -flto
CFLAGS += -std=gnu99 CFLAGS += -std=gnu99

View File

@@ -138,8 +138,8 @@ static char *conf_getpat_concat(const char *restrict s1, const char *restrict s2
buf = ptr; // store the head pointer into buf buf = ptr; // store the head pointer into buf
// copy data to the buffer // copy data to the buffer
ptr = mempcpy(ptr, s1, s1len); // copy s1 data to the buffer ptr = memcpy(ptr, s1, s1len) + s1len; // copy s1 data to the buffer
if (s2len) ptr = mempcpy(ptr, s2, s2len); // copy s2 data to the buffer (excluding null-terminator) if (s2len) ptr = memcpy(ptr, s2, s2len) + s2len; // copy s2 data to the buffer (excluding null-terminator)
(void)strcpy(ptr, s3); // copy s3 as a string, thus including null-terminator (void)strcpy(ptr, s3); // copy s3 as a string, thus including null-terminator
// return the buffer // return the buffer