classification
Title: Carbon.File.FSCatalogInfo.createDate implementation
Type: Stage:
Components: Macintosh Versions: Python 2.4
process
Status: closed Resolution: duplicate
Dependencies: Superseder:
Assigned To: jackjansen Nosy List: jackjansen, ronaldoussoren (2)
Priority: normal Keywords

Created on 2004-12-22 10:21 by ronaldoussoren, last changed 2004-12-22 10:23 by ronaldoussoren.

Messages (2)
msg23802 - (view) Author: Ronald Oussoren (ronaldoussoren) Date: 2004-12-22 10:21
In Mac/Modules/file/_Filemodule.c UTCDateTime values are 
converted using these functions:
 
static int
UTCDateTime_Convert(PyObject *v, UTCDateTime *ptr)
{
        return PyArg_Parse(v, "(HlH)", &ptr->highSeconds, &ptr-
>lowSeconds, &ptr->fraction);
}

static PyObject *
UTCDateTime_New(UTCDateTime *ptr)
{
        return Py_BuildValue("(HlH)", ptr->highSeconds, ptr-
>lowSeconds, ptr->fraction);
}


Shouldn't the format string be "(HLH)" in both cases? The struct 
definition of UTCDateTime contains unsigned times (UInt16, UInt32 
and UInt16).

The same problem is present in Python 2.3
msg23803 - (view) Author: Ronald Oussoren (ronaldoussoren) Date: 2004-12-22 10:23
Logged In: YES 
user_id=580910

whoops, submitted the same bug twice
History
Date User Action Args
2004-12-22 10:21:43ronaldoussorencreate