When setting a QDateTime object to a QDateTimeEdit control the latter completely ignores the time spec of the argument (as documented). Here's the suspect code:
What any reasonable person would expect, however, is to have the date-time converted to the proper specification that was set to the edit, as this relates to the display only, not to the actual point in time. This all means that the following code:
produces different result for the two calls to QDateTimeEdit::setDateTime, which it should not as both arguments point to the same point in time.