aboutsummaryrefslogtreecommitdiff
path: root/bfd/cache.c
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2004-02-11 23:23:20 +0000
committerAndrew Cagney <cagney@redhat.com>2004-02-11 23:23:20 +0000
commit7c1927339f8310bab476aaa4e74e20dbf1cd3deb (patch)
tree555ca47d80702ec8ffb6e7892410ba7baa3d4035 /bfd/cache.c
parent63338fd920b3e8eaad113e0047eff7caaf14f67c (diff)
downloadgdb-7c1927339f8310bab476aaa4e74e20dbf1cd3deb.zip
gdb-7c1927339f8310bab476aaa4e74e20dbf1cd3deb.tar.gz
gdb-7c1927339f8310bab476aaa4e74e20dbf1cd3deb.tar.bz2
2004-02-11 Andrew Cagney <cagney@redhat.com>
* bfd-in.h: Update copyright. (bfd_tell): Change return type to file_ptr. * bfd-in2.h: Re-generate. * cache.c: Update copyright. (bfd_cache_lookup_worker): Use real_fseek, do not cast offset parameter. (close_one): Use real_ftell. * bfdio.c: Update copyright. (real_ftell, real_fseek): New functions. (bfd_tell): Use real_fseek and real_ftell, change return type to file_ptr. (bfd_seek): Use real_ftell and real_fseek, change type of file_position to a file_ptr. * libbfd-in.h: Update copyright. (real_ftell, real_fseek): Declare. * libbfd.h: Re-generate.
Diffstat (limited to 'bfd/cache.c')
-rw-r--r--bfd/cache.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/bfd/cache.c b/bfd/cache.c
index b309165..7d056ea 100644
--- a/bfd/cache.c
+++ b/bfd/cache.c
@@ -1,6 +1,8 @@
/* BFD library -- caching of file descriptors.
- Copyright 1990, 1991, 1992, 1993, 1994, 1996, 2000, 2001, 2002, 2003
- Free Software Foundation, Inc.
+
+ Copyright 1990, 1991, 1992, 1993, 1994, 1996, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
+
Hacked by Steve Chamberlain of Cygnus Support (steve@cygnus.com).
This file is part of BFD, the Binary File Descriptor library.
@@ -155,7 +157,7 @@ close_one (void)
return TRUE;
}
- kill->where = ftell ((FILE *) kill->iostream);
+ kill->where = real_ftell ((FILE *) kill->iostream);
return bfd_cache_delete (kill);
}
@@ -356,7 +358,7 @@ bfd_cache_lookup_worker (bfd *abfd)
return NULL;
if (abfd->where != (unsigned long) abfd->where)
return NULL;
- if (fseek ((FILE *) abfd->iostream, (long) abfd->where, SEEK_SET) != 0)
+ if (real_fseek ((FILE *) abfd->iostream, abfd->where, SEEK_SET) != 0)
return NULL;
}