/[gentoo-projects]/pax-utils/scanelf.c
Gentoo

Diff of /pax-utils/scanelf.c

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

Revision 1.113 Revision 1.114
1/* 1/*
2 * Copyright 2003-2006 Gentoo Foundation 2 * Copyright 2003-2006 Gentoo Foundation
3 * Distributed under the terms of the GNU General Public License v2 3 * Distributed under the terms of the GNU General Public License v2
4 * $Header: /var/cvsroot/gentoo-projects/pax-utils/Attic/scanelf.c,v 1.113 2006/01/24 00:31:58 vapier Exp $ 4 * $Header: /var/cvsroot/gentoo-projects/pax-utils/Attic/scanelf.c,v 1.114 2006/01/24 00:33:05 vapier Exp $
5 * 5 *
6 * Copyright 2003-2006 Ned Ludd - <solar@gentoo.org> 6 * Copyright 2003-2006 Ned Ludd - <solar@gentoo.org>
7 * Copyright 2004-2006 Mike Frysinger - <vapier@gentoo.org> 7 * Copyright 2004-2006 Mike Frysinger - <vapier@gentoo.org>
8 */ 8 */
9 9
10#include "paxinc.h" 10#include "paxinc.h"
11 11
12static const char *rcsid = "$Id: scanelf.c,v 1.113 2006/01/24 00:31:58 vapier Exp $"; 12static const char *rcsid = "$Id: scanelf.c,v 1.114 2006/01/24 00:33:05 vapier Exp $";
13#define argv0 "scanelf" 13#define argv0 "scanelf"
14 14
15#define IS_MODIFIER(c) (c == '%' || c == '#') 15#define IS_MODIFIER(c) (c == '%' || c == '#')
16 16
17 17
877 877
878 found_pax = found_phdr = found_relro = found_load = found_textrel = \ 878 found_pax = found_phdr = found_relro = found_load = found_textrel = \
879 found_rpath = found_needed = found_interp = found_bind = found_soname = \ 879 found_rpath = found_needed = found_interp = found_bind = found_soname = \
880 found_sym = found_lib = found_file = found_textrels = 0; 880 found_sym = found_lib = found_file = found_textrels = 0;
881 881
882 if (be_verbose > 1) 882 if (be_verbose > 2)
883 printf("%s: scanning file {%s,%s}\n", elf->filename, 883 printf("%s: scanning file {%s,%s}\n", elf->filename,
884 get_elfeitype(EI_CLASS, elf->elf_class), 884 get_elfeitype(EI_CLASS, elf->elf_class),
885 get_elfeitype(EI_DATA, elf->data[EI_DATA])); 885 get_elfeitype(EI_DATA, elf->data[EI_DATA]));
886 else if (be_verbose) 886 else if (be_verbose > 1)
887 printf("%s: scanning file\n", elf->filename); 887 printf("%s: scanning file\n", elf->filename);
888 888
889 /* init output buffer */ 889 /* init output buffer */
890 if (!out_buffer) { 890 if (!out_buffer) {
891 out_len = sizeof(char) * 80; 891 out_len = sizeof(char) * 80;
1107 /* now scan the dir looking for fun stuff */ 1107 /* now scan the dir looking for fun stuff */
1108 if ((dir = opendir(path)) == NULL) { 1108 if ((dir = opendir(path)) == NULL) {
1109 warnf("could not opendir %s: %s", path, strerror(errno)); 1109 warnf("could not opendir %s: %s", path, strerror(errno));
1110 return; 1110 return;
1111 } 1111 }
1112 if (be_verbose) printf("%s: scanning dir\n", path); 1112 if (be_verbose > 1) printf("%s: scanning dir\n", path);
1113 1113
1114 pathlen = strlen(path); 1114 pathlen = strlen(path);
1115 while ((dentry = readdir(dir))) { 1115 while ((dentry = readdir(dir))) {
1116 if (!strcmp(dentry->d_name, ".") || !strcmp(dentry->d_name, "..")) 1116 if (!strcmp(dentry->d_name, ".") || !strcmp(dentry->d_name, ".."))
1117 continue; 1117 continue;

Legend:
Removed from v.1.113  
changed lines
  Added in v.1.114

  ViewVC Help
Powered by ViewVC 1.1.20