00001 #include "stdio.h" 00002 #include "tchar.h" 00003 #include "Linux4Win.h" 00004 00009 shm_key_t shmget_win(int key, size_t size) 00010 { 00011 TCHAR key_str[8]; 00012 00013 memset(key_str, 0, sizeof(key_str)); 00014 _stprintf(key_str, _T("0x%04x"), key); 00015 return CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, size, key_str); 00016 }