[dss-commits] digitalSTROM Server branch, master, updated. 29ef16581b96daf7b10ceee0231b2f19c23d1acf

git version control dss-commits at forum.digitalstrom.org
Thu Jan 7 17:18:57 CET 2010


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "digitalSTROM Server".

The branch, master has been updated
       via  29ef16581b96daf7b10ceee0231b2f19c23d1acf (commit)
      from  22db5eed7c26b7956ed4708cccbc2942df46e2d0 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 29ef16581b96daf7b10ceee0231b2f19c23d1acf
Author: Johannes Winkelmann <johannes.winkelmann at aizo.com>
Date:   Thu Jan 7 17:18:50 2010 +0100

    DateTime::clearDate(): reset tm_mday to 1 instead of 0
    
    the valid range of values for tm_mday in struct tm is 1..31

-----------------------------------------------------------------------

Changes:
diff --git a/core/datetools.cpp b/core/datetools.cpp
index 690bf73..e83ded6 100644
--- a/core/datetools.cpp
+++ b/core/datetools.cpp
@@ -169,7 +169,7 @@ namespace dss {
   } // setTime
 
   void DateTime::clearDate() {
-    setDate(0,0,1900);
+    setDate(1, 0, 1900);
   } // clearDate
 
   void DateTime::clearTime() {
diff --git a/tests/datetoolstests.cpp b/tests/datetoolstests.cpp
index 15da7cb..ed59ab8 100644
--- a/tests/datetoolstests.cpp
+++ b/tests/datetoolstests.cpp
@@ -33,7 +33,7 @@ BOOST_AUTO_TEST_SUITE(DateTools)
 BOOST_AUTO_TEST_CASE(testSimpleDates) {
   DateTime dt;
   dt.clear();
-  BOOST_CHECK_EQUAL(dt.getDay(), 0);
+  BOOST_CHECK_EQUAL(dt.getDay(), 1);
   BOOST_CHECK_EQUAL(dt.getMonth(), 0);
   BOOST_CHECK_EQUAL(dt.getYear(), 1900);
   BOOST_CHECK_EQUAL(dt.getSecond(), 0);


hooks/post-receive
-- 
digitalSTROM Server


More information about the dss-commits mailing list