/[LeafOK_CVS]/lbbs/src/user_list.c
ViewVC logotype

Diff of /lbbs/src/user_list.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.34 by sysadm, Mon Nov 17 11:56:11 2025 UTC Revision 1.35 by sysadm, Mon Nov 17 12:16:48 2025 UTC
# Line 531  int set_user_list_pool_shm_readonly(void Line 531  int set_user_list_pool_shm_readonly(void
531          shmid = p_user_list_pool->shmid;          shmid = p_user_list_pool->shmid;
532    
533          // Remap shared memory in read-only mode          // Remap shared memory in read-only mode
534    #if defined(__MSYS__) || defined(__MINGW32__)
535            if (shmdt(p_user_list_pool) == -1)
536            {
537                    log_error("shmdt(user_list_pool) error (%d)\n", errno);
538                    return -1;
539            }
540            p_shm = shmat(shmid, p_user_list_pool, SHM_RDONLY);
541    #else
542          p_shm = shmat(shmid, p_user_list_pool, SHM_RDONLY | SHM_REMAP);          p_shm = shmat(shmid, p_user_list_pool, SHM_RDONLY | SHM_REMAP);
543    #endif
544          if (p_shm == (void *)-1)          if (p_shm == (void *)-1)
545          {          {
546                  log_error("shmat(user_list_pool shmid = %d) error (%d)\n", shmid, errno);                  log_error("shmat(user_list_pool shmid = %d) error (%d)\n", shmid, errno);


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1