*
* Copyright (C) 1994,1996 Alessandro Rubini (rubini@ipvvis.unipv.it)
*
- * Licensed under GPLv2 or later, see file LICENSE in this tarball for details.
+ * Licensed under GPLv2 or later, see file LICENSE in this source tree.
*/
/*
total = 0;
- map = xfopen(mapFile, "r");
+ map = xfopen_for_read(mapFile);
while (fgets(mapline, S_LEN, map)) {
if (sscanf(mapline, "%llx %s %s", &fn_add, mode, fn_name) != 3)
/* ignore any LEADING (before a '[tT]' symbol is found)
Absolute symbols */
if ((*mode == 'A' || *mode == '?') && total == 0) continue;
- if (*mode != 'T' && *mode != 't' &&
- *mode != 'W' && *mode != 'w')
+ if (*mode != 'T' && *mode != 't'
+ && *mode != 'W' && *mode != 'w'
+ ) {
break; /* only text is profiled */
+ }
if (indx >= len / sizeof(*buf))
bb_error_msg_and_die("profile address out of range. "