summaryrefslogtreecommitdiff
path: root/bfd/trad-core.c
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1999-07-11 19:49:48 +0000
committerIan Lance Taylor <ian@airs.com>1999-07-11 19:49:48 +0000
commitd3f2d3dd7467877bcd6e4547064cdb33b7786a75 (patch)
tree671b3ac523ca2b52a551bfe16552a0af0c238b78 /bfd/trad-core.c
parenta50380b5013da41010b2a0717c2e54705441bd23 (diff)
downloadbinutils-redhat-d3f2d3dd7467877bcd6e4547064cdb33b7786a75.tar.gz
* Many files: Changes to avoid gcc warnings: Add ATTRIBUTE_UNUSED
as appropriate. Fill in structure initializations. Add variable initializations. Add casts. * dwarf1.c (parse_line_table): Change eachLine to unsigned long. (dwarf1_unit_find_nearest_line): Change i to unsigned long.
Diffstat (limited to 'bfd/trad-core.c')
-rw-r--r--bfd/trad-core.c21
1 files changed, 12 insertions, 9 deletions
diff --git a/bfd/trad-core.c b/bfd/trad-core.c
index 21d920b0e8..253eb7ad06 100644
--- a/bfd/trad-core.c
+++ b/bfd/trad-core.c
@@ -1,5 +1,5 @@
/* BFD back end for traditional Unix core files (U-area and raw sections)
- Copyright 1988, 89, 91, 92, 93, 94, 95, 96, 1998
+ Copyright 1988, 89, 91, 92, 93, 94, 95, 96, 98, 1999
Free Software Foundation, Inc.
Written by John Gilmore of Cygnus Support.
@@ -105,22 +105,24 @@ trad_unix_core_file_p (abfd)
bfd_set_error (bfd_error_system_call);
return 0;
}
- if (NBPG * (UPAGES + u.u_dsize
+ if ((unsigned long) (NBPG * (UPAGES + u.u_dsize
#ifdef TRAD_CORE_DSIZE_INCLUDES_TSIZE
- - u.u_tsize
+ - u.u_tsize
#endif
- + u.u_ssize) > statbuf.st_size)
+ + u.u_ssize))
+ > (unsigned long) statbuf.st_size)
{
bfd_set_error (bfd_error_file_truncated);
return 0;
}
#ifndef TRAD_CORE_ALLOW_ANY_EXTRA_SIZE
- if (NBPG * (UPAGES + u.u_dsize + u.u_ssize)
+ if ((unsigned long) (NBPG * (UPAGES + u.u_dsize + u.u_ssize)
#ifdef TRAD_CORE_EXTRA_SIZE_ALLOWED
/* Some systems write the file too big. */
- + TRAD_CORE_EXTRA_SIZE_ALLOWED
+ + TRAD_CORE_EXTRA_SIZE_ALLOWED
#endif
- < statbuf.st_size)
+ )
+ < (unsigned long) statbuf.st_size)
{
/* The file is too big. Maybe it's not a core file
or we otherwise have bad values for u_dsize and u_ssize). */
@@ -239,7 +241,7 @@ trad_unix_core_file_failing_command (abfd)
/* ARGSUSED */
int
trad_unix_core_file_failing_signal (ignore_abfd)
- bfd *ignore_abfd;
+ bfd *ignore_abfd ATTRIBUTE_UNUSED;
{
#ifdef TRAD_UNIX_CORE_FILE_FAILING_SIGNAL
return TRAD_UNIX_CORE_FILE_FAILING_SIGNAL(ignore_abfd);
@@ -251,7 +253,8 @@ trad_unix_core_file_failing_signal (ignore_abfd)
/* ARGSUSED */
boolean
trad_unix_core_file_matches_executable_p (core_bfd, exec_bfd)
- bfd *core_bfd, *exec_bfd;
+ bfd *core_bfd ATTRIBUTE_UNUSED;
+ bfd *exec_bfd ATTRIBUTE_UNUSED;
{
return true; /* FIXME, We have no way of telling at this point */
}