summaryrefslogtreecommitdiffstats
path: root/src/H5Gent.c
diff options
context:
space:
mode:
authorRobb Matzke <matzke@llnl.gov>1998-04-14 16:44:46 (GMT)
committerRobb Matzke <matzke@llnl.gov>1998-04-14 16:44:46 (GMT)
commitb6fc6ede10fee24e9ef0a21df81cc181f6d7fec0 (patch)
tree66321165e4bd58a9fe3722a1a3baee2f835d0544 /src/H5Gent.c
parent3f571b6b4499e09aa6db29cb389e1121624a081d (diff)
downloadhdf5-b6fc6ede10fee24e9ef0a21df81cc181f6d7fec0.zip
hdf5-b6fc6ede10fee24e9ef0a21df81cc181f6d7fec0.tar.gz
hdf5-b6fc6ede10fee24e9ef0a21df81cc181f6d7fec0.tar.bz2
[svn-r346] Changes since 19980410
---------------------- ./html/H5.format.html ./src/H5E.c ./src/H5Epublic.h ./src/H5F.c ./src/H5G.c ./src/H5Gent.c ./src/H5Gnode.c ./src/H5Gprivate.h ./src/h5ls.c ./test/Makefile.in Symbolic links are now supported. The ./test/links program will create a `links.h5' file that demonstrates hard links, soft links, dangling links, and recursive links. A symbolic link is a symbol table entity and doesn't have an object header. It's format is described in H5.format.hml. ./src/H5G.c ./src/H5Gpublic.h ./src/h5ls.c Implemented H5Gstat() and H5Gget_linkval() as documented by Quincey. The `H5G_type_t type' field of `H5G_stat_t' was changed to `int type' because H5G_type_t was already used and the `type' data type should be open-ended. ./src/H5Ffamily.c Removed an incorrect diagnostic message. ./test/big.c Added read/write calls to test partial I/O to big contiguous datasets. With no arguments it writes to a dataset and prints the list of points written which should be redirected to a file. With an argument (the name of a file containing the stdout of a run with no arguments) values are read from the dataset. One would typically say `big >x && big x'.
Diffstat (limited to 'src/H5Gent.c')
-rw-r--r--src/H5Gent.c26
1 files changed, 25 insertions, 1 deletions
diff --git a/src/H5Gent.c b/src/H5Gent.c
index 66c08ae..1bcd18f 100644
--- a/src/H5Gent.c
+++ b/src/H5Gent.c
@@ -10,6 +10,7 @@
#include <H5private.h>
#include <H5Eprivate.h>
#include <H5Gpkg.h>
+#include <H5HLprivate.h>
#include <H5MMprivate.h>
#define PABLO_MASK H5G_ent_mask
@@ -204,6 +205,10 @@ H5G_ent_decode(H5F_t *f, const uint8 **pp, H5G_entry_t *ent)
H5F_addr_decode(f, pp, &(ent->cache.stab.heap_addr));
break;
+ case H5G_CACHED_SLINK:
+ UINT32DECODE (*pp, ent->cache.slink.lval_offset);
+ break;
+
default:
HDabort();
}
@@ -310,6 +315,10 @@ H5G_ent_encode(H5F_t *f, uint8 **pp, H5G_entry_t *ent)
H5F_addr_encode(f, pp, &(ent->cache.stab.heap_addr));
break;
+ case H5G_CACHED_SLINK:
+ UINT32ENCODE (*pp, ent->cache.slink.lval_offset);
+ break;
+
default:
HDabort();
}
@@ -350,8 +359,10 @@ H5G_ent_encode(H5F_t *f, uint8 **pp, H5G_entry_t *ent)
*/
herr_t
H5G_ent_debug(H5F_t __unused__ *f, H5G_entry_t *ent, FILE * stream,
- intn indent, intn fwidth)
+ intn indent, intn fwidth, const haddr_t *heap)
{
+ const char *lval = NULL;
+
FUNC_ENTER(H5G_ent_debug, FAIL);
fprintf(stream, "%*s%-*s %lu\n", indent, "", fwidth,
@@ -387,6 +398,19 @@ H5G_ent_debug(H5F_t __unused__ *f, H5G_entry_t *ent, FILE * stream,
fprintf(stream, "\n");
break;
+ case H5G_CACHED_SLINK:
+ fprintf (stream, "Symbolic Link\n");
+ fprintf (stream, "%*s%-*s %lu\n", indent, "", fwidth,
+ "Link value offset:",
+ (unsigned long)(ent->cache.slink.lval_offset));
+ if (heap && H5F_addr_defined (heap)) {
+ lval = H5HL_peek (ent->file, heap, ent->cache.slink.lval_offset);
+ fprintf (stream, "%*s%-*s %s\n", indent, "", fwidth,
+ "Link value:",
+ lval);
+ }
+ break;
+
default:
fprintf(stream, "*** Unknown symbol type %d\n", ent->type);
break;