mirror of
https://github.com/servalproject/serval-dna.git
synced 2025-04-08 03:24:13 +00:00
Fix building and testing on OSX
This commit is contained in:
parent
0255d7938e
commit
7fb1fd7938
4
strbuf.h
4
strbuf.h
@ -88,7 +88,7 @@ struct strbuf {
|
||||
*
|
||||
* @author Andrew Bettison <andrew@servalproject.com>
|
||||
*/
|
||||
#define STRUCT_STRBUF_EMPTY ((struct strbuf){NULL, (char *)NULL - 1, NULL})
|
||||
#define STRUCT_STRBUF_EMPTY ((struct strbuf){NULL, NULL, NULL})
|
||||
|
||||
typedef struct strbuf *strbuf;
|
||||
typedef const struct strbuf *const_strbuf;
|
||||
@ -350,7 +350,7 @@ strbuf strbuf_trunc(strbuf sb, int offset);
|
||||
* @author Andrew Bettison <andrew@servalproject.com>
|
||||
*/
|
||||
__STRBUF_INLINE size_t strbuf_is_empty(const_strbuf sb) {
|
||||
return sb->start == NULL && sb->end == sb->start - 1 && sb->current == NULL;
|
||||
return sb->start == NULL && sb->end == NULL && sb->current == NULL;
|
||||
}
|
||||
|
||||
|
||||
|
@ -175,7 +175,7 @@ runTests() {
|
||||
_tfw_echo_intro $testNumber $testName
|
||||
[ $njobs -ne 1 ] && echo
|
||||
(
|
||||
_tfw_unique=$BASHPID
|
||||
_tfw_unique=$!
|
||||
echo "$testNumber $testName" >"$_tfw_results_dir/$_tfw_unique"
|
||||
_tfw_tmp=/tmp/_tfw-$_tfw_unique
|
||||
trap '_tfw_status=$?; rm -rf "$_tfw_tmp"; exit $_tfw_status' EXIT SIGHUP SIGINT SIGTERM
|
||||
|
Loading…
x
Reference in New Issue
Block a user