diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2002-03-27 20:25:03 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2002-03-27 20:25:03 (GMT) |
commit | 7e9738f290af26d1bf4ab9db64544d9a89505f0a (patch) | |
tree | e5e0986486cbd1440a6acd3adf14cc533c70cfe0 /src/H5FDprivate.h | |
parent | 30aa868e1082ddd7cc59b4f0716434f4a02fcbdd (diff) | |
download | hdf5-7e9738f290af26d1bf4ab9db64544d9a89505f0a.zip hdf5-7e9738f290af26d1bf4ab9db64544d9a89505f0a.tar.gz hdf5-7e9738f290af26d1bf4ab9db64544d9a89505f0a.tar.bz2 |
[svn-r5096] Purpose:
Bug Fix
Description:
The H5Gget_objinfo() function was not setting the 'fileno' field in the
H5G_stat_t struct passed in.
Solution:
Added a "file serial number" to each file currently open in the library
and put that in the 'fileno' field. If a file is opened twice (with
H5Fopen) and the VFL driver detects that it is the same file (i.e. the
two file structures have the same "shared file info" in the library's
memory structures), they will have the same serial number.
This serial number has two drawbacks:
- If a VFL driver doesn't/can't detect that two calls to H5Fopen with
the same file actually _are_ the same file, each will get a
different serial number
- If the same file is closed and re-opened, the serial number will be
different.
It is be possible to fix the second drawback for many VFL drivers, but it
would be a lot of effort and probably isn't worth it until we've got a
good reason to do it. Dunno if we'll ever be able to fix the first
drawback...
Platforms tested:
FreeBSD 4.5 (sleipnir)
VS: ----------------------------------------------------------------------
Diffstat (limited to 'src/H5FDprivate.h')
-rw-r--r-- | src/H5FDprivate.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/H5FDprivate.h b/src/H5FDprivate.h index bd633d0..6e0c919 100644 --- a/src/H5FDprivate.h +++ b/src/H5FDprivate.h @@ -39,5 +39,6 @@ __DLL__ herr_t H5FD_read(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, haddr_t a __DLL__ herr_t H5FD_write(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr, size_t size, const void *buf); __DLL__ herr_t H5FD_flush(H5FD_t *file); +__DLL__ herr_t H5FD_get_fileno(const H5FD_t *file, unsigned long *filenum); #endif /* !_H5FDprivate_H */ |