I have been working with C and I thought that a pointer should not point to a local variable, but the library holds a function gmtime(), which seems to return a pointer to a variable created inside of it. Is my understanding correct?
time_t epochTime;
time(&epochTime);
struct tm *currentTime=gmtime(&epochTime);