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

Diff of /lbbs/src/section_list.c

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

Revision 1.2 by sysadm, Wed May 21 05:36:04 2025 UTC Revision 1.4 by sysadm, Wed May 21 09:09:30 2025 UTC
# Line 16  Line 16 
16    
17  #include "section_list.h"  #include "section_list.h"
18  #include "log.h"  #include "log.h"
 #include "io.h"  
19  #include "trie_dict.h"  #include "trie_dict.h"
20  #include <stdio.h>  #include <stdio.h>
21  #include <string.h>  #include <string.h>
# Line 27  Line 26 
26  #include <sys/shm.h>  #include <sys/shm.h>
27  #include <sys/ipc.h>  #include <sys/ipc.h>
28    
29  #define ARTICLE_BLOCK_PER_SHM 50 // sizeof(ARTICLE_BLOCK) * ARTICLE_BLOCK_PER_SHM is the size of each shm segment to allocate  // ARTICLE_BLOCK_PER_SHM * ARTICLE_BLOCK_SHM_COUNT_LIMIT should be
30  #define ARTICLE_BLOCK_SHM_COUNT_LIMIT 256  // no less than BBS_article_block_limit_per_section * BBS_max_section,
31    // in order to allocate enough memory for blocks
32    #define ARTICLE_BLOCK_PER_SHM 400 // sizeof(ARTICLE_BLOCK) * ARTICLE_BLOCK_PER_SHM is the size of each shm segment to allocate
33    #define ARTICLE_BLOCK_SHM_COUNT_LIMIT 256 // limited by length (8-bit) of proj_id in ftok(path, proj_id)
34    
35  struct article_block_shm_t  struct article_block_shm_t
36  {  {


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

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