title: Shared memory: shm_open fails
body: <p>I'm trying to create a shared memory space on Linux in C, but <code>shm_open</code> keeps failing and returning -1. Could this be because I'm not the root user on this computer?</p>
  
  <p>Here's what I'm trying:</p>
  
  <pre><code>char *name = "name";
  int shm_fd = shm_open(name, O_CREAT|O_RDWR, 0666);
  </code></pre>
  
  <p>but it always returns -1. Any suggestions? I've heard that names for <code>shm_open</code> need to start with a /, so I've tried <code>char *name = "/name"</code> too but still the same. Please help!</p>