From d8c32639e4386268907fc11409639d31cc6826dc Mon Sep 17 00:00:00 2001 From: Dan Cross Date: Thu, 11 Oct 2018 10:51:07 +0000 Subject: [PATCH] Trivial whitespace cleanups Delete trailing whitespace at the ends of lines; ensure files have newlines at the end. Signed-off-by: Dan Cross --- GNUmakefile | 4 ++-- setup.sh | 2 +- src/GNUmakefile.sunos | 2 +- src/hashmap/hashmap.c | 2 +- src/hashmap/main.c | 2 +- src/stralloc/stralloc.c | 10 +++++----- src/stralloc/stralloc.h | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/GNUmakefile b/GNUmakefile index 1561d18..8e3c262 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -7,11 +7,11 @@ all: magicka magicka: cd src && $(MAKE) -f GNUmakefile.$(OS) -www: +www: cd src && $(MAKE) -f GNUmakefile.$(OS) www clean: cd src && $(MAKE) -f GNUmakefile.$(OS) clean - + cleanwww: cd src && $(MAKE) -f GNUmakefile.$(OS) clean diff --git a/setup.sh b/setup.sh index 49da63b..69e3d5b 100755 --- a/setup.sh +++ b/setup.sh @@ -59,7 +59,7 @@ read -e location printstuff "Please enter the name of your BBS:" -read -e bbsname +read -e bbsname PLATFORM=`uname` diff --git a/src/GNUmakefile.sunos b/src/GNUmakefile.sunos index 7a21a3e..13b376b 100644 --- a/src/GNUmakefile.sunos +++ b/src/GNUmakefile.sunos @@ -1,6 +1,6 @@ CC:= gcc CFLAGS:= -std=gnu99 -I/usr/local/include -LIBS:= -L/usr/local/lib -lsqlite3 -lm -ldl -lssl -lcrypto -lssh -lmosquitto -lnsl -lsocket +LIBS:= -L/usr/local/lib -lsqlite3 -lm -ldl -lssl -lcrypto -lssh -lmosquitto -lnsl -lsocket DEPS_LUA_TARGET:= solaris DEPS_JAMLIB_MAKEFILE:= Makefile.sunos diff --git a/src/hashmap/hashmap.c b/src/hashmap/hashmap.c index f8bed2a..6870b7d 100644 --- a/src/hashmap/hashmap.c +++ b/src/hashmap/hashmap.c @@ -393,4 +393,4 @@ int hashmap_length(map_t in) { return m->size; else return 0; -} \ No newline at end of file +} diff --git a/src/hashmap/main.c b/src/hashmap/main.c index 6efebe1..a716c8c 100644 --- a/src/hashmap/main.c +++ b/src/hashmap/main.c @@ -73,4 +73,4 @@ int main(char *argv, int argc) { hashmap_free(mymap); return 1; -} \ No newline at end of file +} diff --git a/src/stralloc/stralloc.c b/src/stralloc/stralloc.c index fcd6cd4..4f2bcf6 100644 --- a/src/stralloc/stralloc.c +++ b/src/stralloc/stralloc.c @@ -5,13 +5,13 @@ #include "stralloc.h" -int stralloc_ready(stralloc *sa, size_t n) { - size_t na; +int stralloc_ready(stralloc *sa, size_t n) { + size_t na; char *ns; assert(sa != NULL); - if (sa->s == NULL) { - sa->len = 0; + if (sa->s == NULL) { + sa->len = 0; sa->a = n; sa->s = malloc(n); return sa != NULL; @@ -25,7 +25,7 @@ int stralloc_ready(stralloc *sa, size_t n) { memset(ns + sa->len, 0, na - sa->len); sa->a = na; sa->s = ns; - return 1; + return 1; } int stralloc_starts(stralloc *sa, const char *s) { diff --git a/src/stralloc/stralloc.h b/src/stralloc/stralloc.h index 7545276..9089284 100644 --- a/src/stralloc/stralloc.h +++ b/src/stralloc/stralloc.h @@ -24,7 +24,7 @@ extern int stralloc_cat_long(stralloc *sa, long v); extern int stralloc_cat_byte(stralloc *sa, int b); extern int stralloc_cat_Byte(stralloc *sa, int b); -static inline int stralloc_readyplus(stralloc *sa, size_t n) { +static inline int stralloc_readyplus(stralloc *sa, size_t n) { assert(sa != NULL); return stralloc_ready(sa, sa->len + n); }