Fixed some Bugs

Related to openbsd_cstpcpy-alloca_true-valid-memsafety.c

Signed-off-by: Herbert <herberthb12@gmail.com>