Debug: use difftime()
authorDaniel Golle <daniel@makrotopia.org>
Thu, 4 Apr 2024 23:39:56 +0000 (00:39 +0100)
committerJeremy Harris <jgh146exb@wizmail.org>
Thu, 4 Apr 2024 23:39:56 +0000 (00:39 +0100)
src/src/transports/smtp.c

index a5f99edaa844f24e31364efa6cc96a6a0c4e6a75..ddd6ad7e13e0d0aef2e516bee623e0f4767bc7a2 100644 (file)
@@ -945,7 +945,8 @@ if (  sx->early_pipe_active
     if (!(er = dbfn_read_enforce_length(dbm_file, ehlo_resp_key, sizeof(dbdata_ehlo_resp))))
       debug_printf("no ehlo-resp record!\n");
     else
-      debug_printf("ehlo-resp record is %d seconds old\n", time(NULL) - er->time_stamp);
+      debug_printf("ehlo-resp record is %.0f seconds old\n",
+                   difftime(time(NULL), er->time_stamp));
     }
 
   dbfn_delete(dbm_file, ehlo_resp_key);