summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--hl/fortran/src/H5TBff.F903
-rw-r--r--hl/fortran/test/tsttable.F904
2 files changed, 4 insertions, 3 deletions
diff --git a/hl/fortran/src/H5TBff.F90 b/hl/fortran/src/H5TBff.F90
index a31c751..5d1ee35 100644
--- a/hl/fortran/src/H5TBff.F90
+++ b/hl/fortran/src/H5TBff.F90
@@ -376,7 +376,8 @@ CONTAINS
INTEGER(size_t), INTENT(in) :: dst_size ! The size of the structure type
INTEGER(size_t), DIMENSION(1:nfields), INTENT(in) :: dst_offset ! An array containing the offsets of the fields
INTEGER(size_t), DIMENSION(1:nfields), INTENT(in) :: dst_sizes ! An array containing the sizes of the fields
- TYPE(C_PTR), INTENT(OUT) :: dst_buf ! Buffer with data
+ TYPE(C_PTR) :: dst_buf ! Buffer with data !! do not use INTENT, causes NAG
+ ! to segfault in C APIs
INTEGER :: errcode ! error code
INTEGER(size_t) :: namelen ! name length
diff --git a/hl/fortran/test/tsttable.F90 b/hl/fortran/test/tsttable.F90
index bffbb03..3cf8fed 100644
--- a/hl/fortran/test/tsttable.F90
+++ b/hl/fortran/test/tsttable.F90
@@ -561,6 +561,7 @@ SUBROUTINE test_table2()
INTEGER, PARAMETER :: dp = SELECTED_REAL_KIND(10) ! This should map to REAL*8 on most modern processors
TYPE particle_t
+ SEQUENCE
CHARACTER(LEN=11) :: name
INTEGER(KIND=i8) :: lati
INTEGER(KIND=i16) :: long
@@ -671,11 +672,10 @@ SUBROUTINE test_table2()
f_ptr1 = C_NULL_PTR
f_ptr2 = C_LOC(fill_data(1)%name(1:1))
-
CALL h5tbmake_table_f("Table Title Fill", file_id, table_name_fill, nfields, nrecords, &
dst_size, field_names, dst_offset, field_type, &
chunk_size, f_ptr2, compress, f_ptr1, errcode )
-
+
f_ptr3 = C_LOC(r_data(1)%name(1:1))
CALL h5tbread_table_f(file_id, table_name_fill, nfields, dst_size, dst_offset, dst_sizes, f_ptr3, errcode)