summaryrefslogtreecommitdiffstats
path: root/src/bfstd.c
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2023-06-19 12:11:36 -0400
committerTavian Barnes <tavianator@tavianator.com>2023-06-20 14:26:09 -0400
commit90ded13e589b0089167ef25ca3d26be599dfec9b (patch)
treed5a007948587f62fff62c851ddd3886b5a5e78ed /src/bfstd.c
parent9ceb2b27577f1be3f30edb40a45117066fc78c51 (diff)
downloadbfs-90ded13e589b0089167ef25ca3d26be599dfec9b.tar.xz
alloc: New header for memory allocation utilities
Diffstat (limited to 'src/bfstd.c')
-rw-r--r--src/bfstd.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/bfstd.c b/src/bfstd.c
index 856c76c..0e8ba5f 100644
--- a/src/bfstd.c
+++ b/src/bfstd.c
@@ -143,19 +143,6 @@ char *xgetdelim(FILE *file, char delim) {
}
}
-void *xmemalign(size_t align, size_t size) {
- bfs_assert(has_single_bit(align));
- bfs_assert((size & (align - 1)) == 0);
-
-#if __APPLE__
- void *ptr = NULL;
- errno = posix_memalign(&ptr, align, size);
- return ptr;
-#else
- return aligned_alloc(align, size);
-#endif
-}
-
/** Compile and execute a regular expression for xrpmatch(). */
static int xrpregex(nl_item item, const char *response) {
const char *pattern = nl_langinfo(item);