If a timestamp initialized to zero was passed to ctdbDateTimeSetDate(), the function was failing with an Invalid Timestamp (4041) error. The logic in ctdbDateTimeSetDate() has been modified to set the Time portion to midnight in such cases without returning an error.