aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2012-03-23 18:04:25 +0100
committerThomas White <taw@physics.org>2012-03-23 18:04:25 +0100
commit61529e35c880db670ee7d5c93b564084814f1ce6 (patch)
treecca0698a21a28aa6bd896f91caab82056018e02b
parente9f46cdce7a927aadd558ddf4cfe41da9dbd1d69 (diff)
Fix hdf5_write_image()
-rw-r--r--libcrystfel/src/hdf5-file.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libcrystfel/src/hdf5-file.c b/libcrystfel/src/hdf5-file.c
index 9b21c444..88d11bff 100644
--- a/libcrystfel/src/hdf5-file.c
+++ b/libcrystfel/src/hdf5-file.c
@@ -351,10 +351,11 @@ int hdf5_write_image(const char *filename, struct image *image)
return 1;
}
+ size[0] = 1;
sh = H5Screate_simple(1, size, NULL);
dh = H5Dcreate2(gh, "photon_energy_eV", H5T_NATIVE_DOUBLE, sh,
- H5P_DEFAULT, ph, H5P_DEFAULT);
+ H5P_DEFAULT, H5S_ALL, H5P_DEFAULT);
if ( dh < 0 ) {
H5Fclose(fh);
return 1;
@@ -370,7 +371,7 @@ int hdf5_write_image(const char *filename, struct image *image)
H5Dclose(dh);
dh = H5Dcreate2(fh, "/LCLS/photon_wavelength_A", H5T_NATIVE_DOUBLE, sh,
- H5P_DEFAULT, ph, H5P_DEFAULT);
+ H5P_DEFAULT, H5S_ALL, H5P_DEFAULT);
if ( dh < 0 ) {
H5Fclose(fh);
return 1;