mirror of
https://github.com/thunderbrewhq/squall.git
synced 2025-12-12 10:32:29 +00:00
feat(string): add STORM_MAX_PATH and STORM_MAX_STR
This commit is contained in:
parent
abb9e8ed79
commit
e74eb83854
2 changed files with 4 additions and 1 deletions
|
|
@ -134,7 +134,7 @@ size_t SStrCopy(char* dest, const char* source, size_t destsize) {
|
||||||
|
|
||||||
char* destbuf = dest;
|
char* destbuf = dest;
|
||||||
|
|
||||||
if (destsize == 0x7FFFFFFF) {
|
if (destsize == STORM_MAX_STR) {
|
||||||
while (*source) {
|
while (*source) {
|
||||||
*destbuf = *source;
|
*destbuf = *source;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
|
|
||||||
|
#define STORM_MAX_PATH 260
|
||||||
|
#define STORM_MAX_STR 0x7FFFFFFF
|
||||||
|
|
||||||
size_t SStrCopy(char* dest, const char* source, size_t destsize);
|
size_t SStrCopy(char* dest, const char* source, size_t destsize);
|
||||||
|
|
||||||
uint32_t SStrHashHT(const char* string);
|
uint32_t SStrHashHT(const char* string);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue