summaryrefslogtreecommitdiff
path: root/libmysqlpp
diff options
context:
space:
mode:
Diffstat (limited to 'libmysqlpp')
-rw-r--r--libmysqlpp/command.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/libmysqlpp/command.cpp b/libmysqlpp/command.cpp
index 04628ec..1b1b4ae 100644
--- a/libmysqlpp/command.cpp
+++ b/libmysqlpp/command.cpp
@@ -135,6 +135,9 @@ MySQL::Command::bindParamT(unsigned int n, const boost::posix_time::time_duratio
binds[n].buffer_type = MYSQL_TYPE_TIME;
binds[n].buffer = realloc(binds[n].buffer, sizeof(MYSQL_TIME));
MYSQL_TIME & ts = *static_cast<MYSQL_TIME*>(binds[n].buffer);
+ ts.year = 0;
+ ts.month = 0;
+ ts.day = 0;
ts.hour = v.hours();
ts.minute = v.minutes();
ts.second = v.seconds();