From 8c49663b547138d279e79985dc6b7677320328b2 Mon Sep 17 00:00:00 2001 From: mothran Date: Sat, 21 Mar 2015 10:11:29 -0700 Subject: [PATCH 1/3] calmed some clang warning --- src/core_notes.c | 2 +- src/core_text.c | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/core_notes.c b/src/core_notes.c index 2aeff08..c3c0fca 100644 --- a/src/core_notes.c +++ b/src/core_notes.c @@ -102,7 +102,7 @@ static void print_nt_files(struct nt_file_struct *file_maps) notedesc_t * parse_notes_area(elfdesc_t *elfdesc) { notedesc_t *notedesc = (notedesc_t *)heapAlloc(sizeof(notedesc_t)); - size_t i, j, len; + size_t i, len; int tc, fpregset_count = 0, fpxregset_count = 0; uint8_t *desc; struct nt_file_struct *nt_files; // for parsing NT_FILE in corefile diff --git a/src/core_text.c b/src/core_text.c index f8de97a..cdc792e 100644 --- a/src/core_text.c +++ b/src/core_text.c @@ -103,7 +103,6 @@ int merge_exe_text_into_core(const char *path, memdesc_t *memdesc) uint8_t *mem; struct stat st; int in, out, i = 0; - int data_index; in = xopen(path, O_RDWR); xfstat(in, &st); From a5afecfcb467d1b04777be2a9920b96cd0fa2137 Mon Sep 17 00:00:00 2001 From: mothran Date: Sat, 21 Mar 2015 10:13:44 -0700 Subject: [PATCH 2/3] removed anouther warning about unsigned long vs int's --- main/readecfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/readecfs.c b/main/readecfs.c index 751dbe3..7afcaa3 100644 --- a/main/readecfs.c +++ b/main/readecfs.c @@ -220,7 +220,7 @@ int main(int argc, char **argv) ret = get_fd_info(desc, &fdinfo); printf("- files/pipes/sockets (.fdinfo):\n"); for (i = 0; i < ret; i++) { - printf("\t[fd: %d:%d] perms: %lx path: %s\n", fdinfo[i].fd, (int)fdinfo[i].pos, fdinfo[i].perms, fdinfo[i].path); + printf("\t[fd: %d:%d] perms: %x path: %s\n", fdinfo[i].fd, (int)fdinfo[i].pos, fdinfo[i].perms, fdinfo[i].path); if (fdinfo[i].net) { switch(fdinfo[i].net) { case NET_TCP: From 6b80633219a83ab7dcabd8658a8ec0e2d9499f24 Mon Sep 17 00:00:00 2001 From: mothran Date: Sun, 22 Mar 2015 20:50:34 -0700 Subject: [PATCH 3/3] removed anouther 'j' var that was unused --- main/ecfs_snapshot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/ecfs_snapshot.c b/main/ecfs_snapshot.c index 5cf51a6..722f99a 100644 --- a/main/ecfs_snapshot.c +++ b/main/ecfs_snapshot.c @@ -279,7 +279,7 @@ int main(int argc, char **argv) notedesc_t *notedesc = NULL; handle_t *handle = alloca(sizeof(handle_t)); pid_t pid = 0; - int i, j, ret, c, pie = 0; + int i, ret, c, pie = 0; char *corefile = NULL; char *outfile = NULL; list_t *list_head;