use pthread_getspecific instead of __thread

This commit is contained in:
Cloud Wu
2014-04-24 17:55:43 +08:00
parent bd3aa3f3c5
commit bad9a5fc54
6 changed files with 52 additions and 14 deletions

View File

@@ -2,6 +2,8 @@
#include "skynet_imp.h"
#include "skynet_env.h"
#include "skynet_server.h"
#include "malloc_hook.h"
#include <stdio.h>
#include <stdlib.h>
@@ -87,6 +89,9 @@ main(int argc, char *argv[]) {
if (argc > 1) {
config_file = argv[1];
}
skynet_globalinit();
malloc_inithook();
skynet_env_init();
sigign();
@@ -129,6 +134,7 @@ main(int argc, char *argv[]) {
lua_close(L);
skynet_start(&config);
skynet_globalexit();
printf("skynet exit\n");