thank you very much Adak, it worked as it should.
Type: Posts; User: Donald Salguero
thank you very much Adak, it worked as it should.
The only variable that causes me problems is the minute int. The hours are as they should be, and i can do the proper operations with them.
If i had to guess is that after scanning the hours and...
i tried using
sscanf(pt, "%*s %d %s %d %d %*[^:]c %d", d, month, y, h, min);
sscanf(pt, "%*s %d %s %d %d %[^:]c %d", d, month, y, h, min);
but the minute int always ended up as 0 even though the...
the complete string that i scan has the following format:
"Date: dd month yyyy hh:mm:ss"
the time is formatted as
hh:mm:ss
i want the hour int (*h) to be hh, and the minute int (*m) to be...
i have the following function
void fixdate(char *pt, int* d, int* m, int* y, int* h, int* min, int* pa)
{
char month[3];
sscanf(pt, "%*s %d %s %d %d %d", d, month, y, h, min);