diff options
author | Yunchih Chen <yunchih.cat@gmail.com> | 2017-12-01 11:01:58 +0800 |
---|---|---|
committer | Yunchih Chen <yunchih.cat@gmail.com> | 2017-12-01 11:01:58 +0800 |
commit | 15f0360911c3ff0a25f36820c41f54d265ccbd81 (patch) | |
tree | 67b90cc1aa6bfd301efaba03e97ce46f9f238882 | |
parent | ec0e71f4c1eefce0ae650c9340522c377a6abff3 (diff) | |
download | nfcollect-15f0360911c3ff0a25f36820c41f54d265ccbd81.tar.gz nfcollect-15f0360911c3ff0a25f36820c41f54d265ccbd81.tar.zst nfcollect-15f0360911c3ff0a25f36820c41f54d265ccbd81.zip |
Remove unused comment
-rw-r--r-- | commit.c | 1 | ||||
-rw-r--r-- | main.c | 20 |
2 files changed, 0 insertions, 21 deletions
@@ -5,7 +5,6 @@ extern char *storage_dir; extern char *storage_prefix; const uint32_t write_blk_size = 8196; -const uint32_t commit_file_open_flag = O_RDWR | O_CREAT | O_APPEND | O_DIRECT; void nfl_commit_init() { @@ -56,26 +56,6 @@ void sig_handler(int signo) { /* TODO */ } } -/* -void *open_trunk_storage(uint32_t size){ - int fd; - - // open file and map to memory - ERR((fd = open(mapfile, O_RDWR | O_CREAT | O_TRUNC, (mode_t)0600)) == -1, - "Could not open file"); - - ERR(lseek(fd, size - 1, SEEK_SET) == -1, - "Could not seek to end of file"); - - // ERR(fallocate(fd, 0, 0, storage_size_byte) == -1, - // "Could not seek to end of file"); - - ERR(write(fd, "", 1) == -1, "Could not write to end of file"); - - return mmap(NULL, size, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0); -} -*/ - nflog_state_t *get_nflog_state(uint32_t id, uint32_t entries_max) { nflog_state_t *state = (nflog_state_t *)malloc(sizeof(nflog_state_t)); |