Thread safe alternative to mktime() in SunOS 5.5?

Thread safe alternative to mktime() in SunOS 5.5?

Post by Kosh Banerj » Wed, 04 Aug 1999 04:00:00



According to the man page, mktime() is not thread safe. (I really don't see
why it's not thread safe.) Anyone know of a thread safe alternative? An e-mail
reply at the following address would be greatly appreciated:


Thanks.

K. Banerjee

 
 
 

1. opendir(), SunOS 4.1.3, SunOS 5.5 compatibility

Given the following program:

#include <stdio.h>
#include <dirent.h>

int
main (argc, argv)
        int argc;
        char **argv;
{
        DIR     *dir;

        if (argc < 2) return 1;

        dir = opendir (argv[1]);
        if (dir == NULL) {
                perror (argv[1]);
        } else {
                printf ("opened %s\n", argv[1]);
                closedir (dir);
        }
        return 0;

Compiled on SunOS 4.1.{3,4} with cc or gcc, either static or dynamic
linking, run on SunOS 5.5, gives an odd appearing problem:

% test/dir /usr/lib/locale
/usr/lib/locale: No such file or directory
% test/dir /usr/lib/spell
opened /usr/lib/spell
% ls -ldg /usr/lib/locale /usr/lib/spell
drwxr-xr-x  41 bin      bin          1024 May 10  1996 /usr/lib/locale/
dr-xr-xr-x   2 bin      bin           512 May 10  1996 /usr/lib/spell/
%

Some other directories with "locale" in the path also fail.

Explanation?

--
------------------------------------------------------------------------

Unsolicited bulk or commercial email is not welcome.             netcom.com
No warranty of any kind is provided with this message.

2. Best DVR distro

3. how do I get banner pages on SunOS 5.5 and SunOS 4.x?

4. Linux_emul syslog message

5. thread safe mktime functionality?

6. LWP book wanted

7. Solaris 8 threads: If a routine is Async-Signal-Safe is it also thread Safe?

8. Metro keyboard troubles

9. Any suggestions regarding an Exchange 5.5 alternative?

10. MS-exchange 5.5 DNS configuration on solaris 5.5

11. thread safe alternative to rexec?

12. Thread safe alternative to system() on Solaris 2.6?

13. Framemaker 5.5/SunOS 5.7 trouble