(/home/sate/Testcases/c/cve/dovecot-1.2.0/src/lib-index/mail-transaction-log.c) |
| |
| 282 | | | mail_transaction_log_refresh(struct mail_transaction_log *log, bool nfs_flush) |
| 283 | | | { |
| 284 | | | struct mail_transaction_log_file *file; |
| 285 | | | struct stat st; |
| 286 | | | const char *path; |
| 287 | | | |
| 288 | | | i_assert(log->head != NULL);
x /home/sate/Testcases/c/cve/dovecot-1.2.0/src/lib/macros.h |
| |
189 | #define i_assert(expr) STMT_START{ \ |
190 | if (unlikely(!(expr))) \ |
191 | i_panic("file %s: line %d (%s): assertion failed: (%s)", \ |
192 | __FILE__, \ |
193 | __LINE__, \ |
194 | __PRETTY_FUNCTION__, \ |
195 | #expr); }STMT_END |
| |
|
Event 1:
Skipping " if". log->head != (void *)0 evaluates to true.
hide
Event 2:
Skipping " if". !(log->head != (void *)0) evaluates to false.
hide
Event 3:
Skipping " if". !!(log->head != (void *)0) evaluates to true.
hide
Event 4:
Skipping " if". !!!(log->head != (void *)0) evaluates to false.
hide
Event 5:
Skipping " if". __builtin_expect(...) evaluates to false.
hide
|
|
| 289 | | | |
| 290 | | | if (MAIL_TRANSACTION_LOG_FILE_IN_MEMORY(log->head)) |
Event 6:
Skipping " if". log->head->fd == -1 evaluates to false.
hide
|
|
| 291 | | | return 0; |
| 292 | | | |
| 293 | | | path = t_strconcat(log->index->filepath, |
Event 12:
path is set to t_strconcat(...), which evaluates to NULL. See related event 11.
hide
|
|
| 294 | [+] | | MAIL_TRANSACTION_LOG_SUFFIX, NULL); |
 |
| 295 | | | if (log->index->nfs_flush && nfs_flush) |
Event 13:
Skipping " if". log->index->nfs_flush evaluates to false.
hide
|
|
| 296 | | | nfs_flush_file_handle_cache(path); |
| 297 | [+] | | if (nfs_safe_stat(path, &st) < 0) { |
 |
| 298 | | | if (errno != ENOENT) {
x /usr/include/asm-generic/errno-base.h |
| |
5 | #define ENOENT 2 /* No such file or directory */ |
| |
|
| 299 | | | mail_index_file_set_syscall_error(log->index, path, |
| 300 | | | "stat()"); |
| 301 | | | return -1; |
| 302 | | | } |
| 303 | | | |
| 304 | | | |
| 305 | | | |
| 306 | | | file = log->head; |
| 307 | | | if (mail_transaction_log_create(log, FALSE) < 0) |
| 308 | | | return -1; |
| 309 | | | i_assert(file->refcount > 0);
x /home/sate/Testcases/c/cve/dovecot-1.2.0/src/lib/macros.h |
| |
189 | #define i_assert(expr) STMT_START{ \ |
190 | if (unlikely(!(expr))) \ |
191 | i_panic("file %s: line %d (%s): assertion failed: (%s)", \ |
192 | __FILE__, \ |
193 | __LINE__, \ |
194 | __PRETTY_FUNCTION__, \ |
195 | #expr); }STMT_END |
| |
|
| 310 | | | file->refcount--; |
| 311 | | | log->index->need_recreate = TRUE; |
| 312 | | | return 0; |
| 313 | | | } else if (log->head->st_ino == st.st_ino && |
Event 16:
Skipping " if". log->head->st_ino == st.st_ino evaluates to false.
hide
|
|
| 314 | | | CMP_DEV_T(log->head->st_dev, st.st_dev)) {
x /home/sate/Testcases/c/cve/dovecot-1.2.0/src/lib/compat.h |
| |
59 | # define CMP_DEV_T(a, b) (major(a) == major(b) && minor(a) == minor(b)) |
| |
x /usr/include/sys/sysmacros.h |
| |
65 | # define major(dev) gnu_dev_major (dev) |
| |
x /usr/include/sys/sysmacros.h |
| |
65 | # define major(dev) gnu_dev_major (dev) |
| |
x /usr/include/sys/sysmacros.h |
| |
66 | # define minor(dev) gnu_dev_minor (dev) |
| |
x /usr/include/sys/sysmacros.h |
| |
66 | # define minor(dev) gnu_dev_minor (dev) |
| |
|
| 315 | | | |
| 316 | | | |
| 317 | | | |
| 318 | | | |
| 319 | | | |
| 320 | | | return 0; |
| 321 | | | } |
| 322 | | | |
| 323 | [+] | | file = mail_transaction_log_file_alloc(log, path); |
Event 17:
path, which evaluates to NULL, is passed to mail_transaction_log_file_alloc() as the second argument. See related event 12.
hide
|
|
 |
| |