changeset 259:39d2fc310eb9 src

fix the printerr macro again to have \0-terminated strings
author mroi
date Sat, 15 Jan 2005 14:48:35 +0000
parents 0f055e94eb9c
children 97ad00b13609
files dvdnav_internal.h
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/dvdnav_internal.h	Sat Jan 15 14:42:50 2005 +0000
+++ b/dvdnav_internal.h	Sat Jan 15 14:48:35 2005 +0000
@@ -198,6 +198,6 @@
 #endif /* WIN32 */
 #endif
 #define printerr(str) \
-	do { if (this) strncpy(this->err_str, str, MAX_ERR_LEN); } while (0)
+	do { if (this) strncpy(this->err_str, str, MAX_ERR_LEN - 1); } while (0)
 
 #endif /* DVDNAV_INTERNAL_H_INCLUDED */