Check STR_SIZE_MAX in Strcat_char

This commit is contained in:
Tatsuya Kinoshita
2021-03-21 12:51:08 +09:00
parent 4da429056b
commit 15520de3aa
2 changed files with 3 additions and 3 deletions

2
Str.c
View File

@@ -21,12 +21,10 @@
#ifdef __EMX__ /* or include "fm.h" for HAVE_BCOPY? */
#include <strings.h>
#endif
#include <limits.h>
#include "Str.h"
#include "myctype.h"
#define INITIAL_STR_SIZE 32
#define STR_SIZE_MAX (INT_MAX / 32)
#ifdef STR_DEBUG
/* This is obsolete, because "Str" can handle a '\0' character now. */