comparison liboctave/oct-time.cc @ 7065:97db94ae2cf0

[project @ 2007-10-25 05:50:55 by jwe]
author jwe
date Thu, 25 Oct 2007 05:50:56 +0000
parents ad2aaf824128
children 2eb392d058bb
comparison
equal deleted inserted replaced
7064:faff87ff9d5a 7065:97db94ae2cf0
314 void 314 void
315 octave_localtime::init (const octave_time& ot) 315 octave_localtime::init (const octave_time& ot)
316 { 316 {
317 tm_usec = ot.usec (); 317 tm_usec = ot.usec ();
318 318
319 time_t t = ot; 319 time_t t = ot.unix_time ();
320 320
321 octave_base_tm::init (localtime (&t)); 321 octave_base_tm::init (localtime (&t));
322 } 322 }
323 323
324 void 324 void
325 octave_gmtime::init (const octave_time& ot) 325 octave_gmtime::init (const octave_time& ot)
326 { 326 {
327 tm_usec = ot.usec (); 327 tm_usec = ot.usec ();
328 328
329 time_t t = ot; 329 time_t t = ot.unix_time ();
330 330
331 octave_base_tm::init (gmtime (&t)); 331 octave_base_tm::init (gmtime (&t));
332 } 332 }
333 333
334 void 334 void