diff options
author | Daniel Jones <admin@danieljon.es> | 2019-12-31 16:11:36 +1030 |
---|---|---|
committer | Daniel Jones <admin@danieljon.es> | 2019-12-31 16:11:36 +1030 |
commit | ddebb616f923bc8abd9e1176b0cfdf7d8cab78d7 (patch) | |
tree | 1bef0fff26f2f2f65c884930ac7ac123be363e83 /pages.c | |
parent | e561e23c31040d1ad355fcce2e81feaa7daf9cde (diff) | |
download | websitegenerator-ddebb616f923bc8abd9e1176b0cfdf7d8cab78d7.tar.gz websitegenerator-ddebb616f923bc8abd9e1176b0cfdf7d8cab78d7.zip |
added array of posts to ignore
Diffstat (limited to 'pages.c')
-rw-r--r-- | pages.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -484,6 +484,18 @@ postspage(int flags) { if (strstr(ent->d_name, ".txt") != NULL) { + int ign = 0; + /* check if post should be ignored */ + for (int i = 0; i < sizeof(ignore)/sizeof(ignore[0]); i++) + { + if (atoi(ent->d_name) == ignore[i]) + { + printf("ignoring post %d\n", atoi(ent->d_name)); + ign = 1; + } + } + if (ign) + continue; posts[totalposts] = atoi(ent->d_name); // gross totalposts++; } |