Bug in 64bit cocos gettimeofday

Hi.

I’m using cocos2d-x built in 64 bits on MacOSX.
Found a bug in gettimeofdayCocos2d cocos implementation related to 32/64 differences.

Current cocos implementation:

int CCTime::gettimeofdayCocos2d(struct cc_timeval *tp, void *tzp)
{
    CC_UNUSED_PARAM(tzp);
    if (tp)
    {
        gettimeofday((struct timeval *)tp,  0);
    }
    return 0;
}

The problem is that tp~~>tv_usec contains garbage after this function returns.
Look at this :
<pre>
int CCTime::gettimeofdayCocos2d
{
CC_UNUSED_PARAM;
if
{
timeval tv;
gettimeofdaytp, 0);
CCLog, sizeof, sizeof, sizeof);
}
return 0;
}
</pre>
Output:
cocos2d-x debug info Sizes. Left: 8, 8. Right: 8, 4.
Structs are not equal on 64 bit!
Possible solution:
<pre>
int CCTime::gettimeofdayCocos2d
{
CC_UNUSED_PARAM;
if
{
timeval tv;
gettimeofday&tv, 0);
tp~~>tv_sec = tv.tv_sec;
tp->tv_usec = tv.tv_usec;
}
return 0;
}

Please, fix it.