summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStanislav Malyshev <stas@php.net>2007-02-16 18:48:53 +0000
committerStanislav Malyshev <stas@php.net>2007-02-16 18:48:53 +0000
commit8edc9018db66adfe703dd0b8b2ee71dfb5b6c082 (patch)
treed0f3130fa9804d64e3c9e77134235834d12ac1e4
parent1fd2039fdd9cb6b54927a0c64564e178d7d6e820 (diff)
downloadphp-git-8edc9018db66adfe703dd0b8b2ee71dfb5b6c082.tar.gz
use error message size
-rw-r--r--ext/mysqli/mysqli.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c
index 92106125cf..e31d09a2c7 100644
--- a/ext/mysqli/mysqli.c
+++ b/ext/mysqli/mysqli.c
@@ -1130,10 +1130,10 @@ int php_local_infile_error(void *ptr, char *error_msg, uint error_msg_len)
mysqli_local_infile *data = (mysqli_local_infile *) ptr;
if (data) {
- strcpy(error_msg, data->error_msg);
+ strlcpy(error_msg, data->error_msg, error_msg_len);
return 2000;
}
- strcpy(error_msg, ER(CR_OUT_OF_MEMORY));
+ strlcpy(error_msg, ER(CR_OUT_OF_MEMORY), error_msg_len);
return CR_OUT_OF_MEMORY;
}
/* }}} */