mirror of
https://github.com/NVIDIA/cuda-samples.git
synced 2026-11-18 09:58:18 +08:00
Bug 5502937: Set TEMPDIR as socket create dir to avoid socket create permission isue on systems like WSL
This commit is contained in:
@@ -52,14 +52,12 @@
|
||||
#include <memory.h>
|
||||
#include <sys/un.h>
|
||||
#endif
|
||||
#include <filesystem>
|
||||
#include <vector>
|
||||
|
||||
// Define "/tmp" as socket creating folder for QNX
|
||||
#if defined(__QNX__)
|
||||
#define SOCK_FOLDER "/tmp/"
|
||||
#else
|
||||
#define SOCK_FOLDER ""
|
||||
#endif
|
||||
inline std::string getSocketFolder() {
|
||||
return std::filesystem::temp_directory_path().string();
|
||||
}
|
||||
|
||||
typedef struct sharedMemoryInfo_st {
|
||||
void *addr;
|
||||
|
||||
Reference in New Issue
Block a user