diff options
author | Matthew Kosarek <mattkae@protonmail.com> | 2021-05-16 19:49:37 -0400 |
---|---|---|
committer | Matthew Kosarek <mattkae@protonmail.com> | 2021-05-16 19:49:37 -0400 |
commit | 4941a1874b6ca9d142d94df70b2aec5e0b35b94e (patch) | |
tree | 64e0d585420230213bb9eee57f2be0a3325e766d /backend/stringmanip.h | |
parent | 61128756e24e88d84bd77cd4993b5f14284791f0 (diff) |
Removed the entirety of the backend
Diffstat (limited to 'backend/stringmanip.h')
-rw-r--r-- | backend/stringmanip.h | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/backend/stringmanip.h b/backend/stringmanip.h deleted file mode 100644 index c5a32dc..0000000 --- a/backend/stringmanip.h +++ /dev/null @@ -1,27 +0,0 @@ -#pragma once -#include <string.h> - -void copyUntilStr(char* destination, char* source, const char* cmpstr) { - int index = 0; - char* ptr = source; - int cmpStrLen = strlen(cmpstr); - while (strncmp(ptr, cmpstr, cmpStrLen) != 0) { - destination[index++] = *ptr; - ptr++; - } - - destination[index] = '\0'; -} - -int endsWith(const char *str, const char *suffix) { - size_t str_len = strlen(str); - size_t suffix_len = strlen(suffix); - - return (str_len >= suffix_len) && - (!memcmp(str + str_len - suffix_len, suffix, suffix_len)); -} - -void getCurrentDateStr(char* text) { - time_t now = time(NULL); - sprintf(text, "%s GMT", ctime(&now)); -}
\ No newline at end of file |