summaryrefslogtreecommitdiffstats
path: root/src/H5detect.c
Commit message (Collapse)AuthorAgeFilesLines
* Normalization with vol_integration (misc internal and datatype)Dana Robinson2018-09-201-211/+210
|
* Fix whitespace and exit statusAllen Byrne2018-09-181-240/+203
|
* HDFFV-9059 Allow detect to take a file as an argumentAllen Byrne2018-09-181-386/+321
|
* Fix evaluation of __has_attribute(no_sanitize_address) on older GCC versionsJerome Soumagne2018-07-161-3/+7
|
* Merge pull request #1112 in HDFFV/hdf5 from ↵Jerome Soumagne2018-07-161-7/+5
|\ | | | | | | | | | | | | ~JSOUMAGNE/hdf5_fork:gcc_sanitize to develop * commit '5afeefe1bae62fa5faf06c0c6f240e10863a2693': Fix H5detect to use no_sanitize_address attribute and support GCC sanitizers
| * Fix H5detect to use no_sanitize_address attribute and support GCC sanitizersJerome Soumagne2018-06-151-7/+5
| |
* | Fixed HDFFV-10404Binh-Minh Ribler2018-07-131-6/+6
|/ | | | | | | | | Description: Applied the typo fixes from user's report. The previous pull request couldn't be merged because it was too old, and it was too complicated for me to resolve conflicts. Platform tested: Linux/64 (jelly) - very minor
* GGC requires attribute before functionAllen Byrne2018-05-091-20/+20
|
* HDFFV-10345 spelling errorsAllen Byrne2018-02-051-2/+2
|
* HDFFV-10398 avoid sanitizer failuresAllen Byrne2018-01-301-511/+527
|
* Merge pull request #426 in HDFFV/hdf5 from ~LRKNOX/hdf5_lrk:hdf5_1_10 to ↵Larry Knox2017-04-251-12/+8
| | | | | | | | | | hdf5_1_10 * commit '54957d37f5aa73912763dbb6e308555e863c43f4': Commit copyright header change for src/H5PLpkg.c which was added after running script to make changes. Add new files in release_docs to MANIFEST. Cimmit changes to Makefile.in(s) and H5PL.c that resulted from running autogen.sh. Merge pull request #407 in HDFFV/hdf5 from ~LRKNOX/hdf5_lrk:hdf5_1_10_1 to hdf5_1_10_1 Change copyright headers to replace url referring to file to be removed and replace it with new url for COPYING file.
* [svn-r30113] Description:Quincey Koziol2016-06-281-1/+1
| | | | | | | | Clean up warnings (from 2774 -> 1560, with my standard debug build) Tested on: MacOSX/64 10.11.5 (amazon) w/serial, parallel & production (h5committest forthcoming)
* [svn-r27768] Description:Quincey Koziol2015-09-141-5/+5
| | | | | | | | | | | | | | | | | | | | | | Complete revamp of package initialization/shutdown mechanism in the library. Each package now has a single init/term routine. This new way should avoid packages being re-initialized during library shutdown and is also be _much_ more proactive about giving feedback for resource leaks internal to the library. Introduces a new "module" header file for packages in the library (e.g src/H5Fmodule.h) which sets up some necessary package configuration macros for the FUNC_ENTER/LEAVE macros. (The VFL drivers have their own slightly modified version of this header, src/H5FDdrvr_module.h) Also cleaned up a bunch of resources leaks all across the library and tests, along with addressing many warnings, as I encountered them. Tested on: MacOSX/64 10.10.5 (amazon) w/serial & parallel Linux/64 3.10.x (kituo) w/serial & parallel Linux/64 2.6.x (ostrich) w/serial
* [svn-r27133] - Add a new attribute function characterstic for format:Mohamad Chaarawi2015-06-011-3/+3
| | | | | | | | * H5_ATTR_FORMAT(X,Y,Z) __attribute__((format(X, Y, Z))) - Rename UNUSED attribute characterstic to H5_ATTR_UNUSED. - Rename NORETURN attribute characterstic to H5_ATTR_NORETURN tested with h5committest.
* [svn-r27114] Fixed spelling and which file is created with the program.Scot Breitenfeld2015-05-271-1/+1
| | | | Tested: none -- comments only.
* [svn-r27031] Fix warnings in H5detect and clean up code, use unsigned variablesJerome Soumagne2015-05-061-149/+152
| | | | | | | | | | | | | | | | | | | | | | Use H5_GCC_DIAG_ON/OFF to suppress larger-than and float-equal warnings Variables used with sigsetjmp/siglongjmp must be declared as volatile Remove unnecessary use of volatile after r24171 fix and fix prototypes Tested in release mode on: - jam (CentOS 5.11 i386 GCC 4.1.2) - ostrich (RHEL 6.6 ppc64 GCC 4.4.7) - local linux (OpenSuSE 13.2 x86_64 GCC 4.8.3) - local linux (Fedora 21 x86_64 GCC 4.9.2) - local linux (Fedora 21 x86_64 ICC 15.0.2) - local windows (Windows 8.1 x86_64 MSVC 2013 update 4) - lemur (MacOSX 10.10.3 x86_64 clang-602.0.49 Xcode 6.3.1) - ibm p95a07 (Ubuntu 14.10 ppc64le GCC 4.9.1) - ibm p95a07 (Ubuntu 14.10 ppc64le IBM XL C V13.1.1) - bluewaters (Cray PE 2.2.1 x86_64 GCC 4.8.2) - bluewaters (Cray PE 2.2.1 x86_64 Cray C 8.3.3) - bluewaters (Cray PE 2.2.1 x86_64 PGCC 14.2)
* [svn-r27029] Fix bad comment in H5detect, this was preventing PGCC from ↵Jerome Soumagne2015-05-061-1/+1
| | | | | | compiling correctly. Tested on: bluewaters
* [svn-r26375] Print number of times sigill_handler is called in H5detect.Jerome Soumagne2015-03-051-6/+11
| | | | Part of: HDFFV-8857
* [svn-r26333] Eliminates gcc warnings due to -Wunsuffixed-float-constants.Dana Robinson2015-03-011-12/+12
| | | | | | | | | | | | - Adds 'F' suffixes for most float constants. - A few constants MUST be of type double. These now receive the long double L suffix and are then cast to double. I do this via a new H5_DOUBLE() macro which was added to H5private.h. Fixes: HDFFV-9148 Tested on: h5committest
* [svn-r24757] Change assertion to condition check/error return. Should fix ↵Neil Fortner2014-03-031-1/+1
| | | | | | | | | | periodic assertion failure in fheap test (in test that is expected to fail cleanly). Fix type in H5detect.c Tested: ostrich, platypus (h5committest - jam and koala having issues)
* [svn-r24368] Issue 8147 - clang's -fcatch-undefined-behavior exposed ↵Raymond Lu2013-10-281-4/+43
| | | | | | | undefined behavior in the alignment detection algorithm for integers in H5detect.c. Quincey decided to solve it in two steps. First, catch illegal instruction signal in the original algorithm. Second, use POSIX __alignof function to detect alignment if it's available. This checkin is the first step. Tested on wren, jam, ostrich, platypas, and koala.
* [svn-r24333] Added a few volatile keywords to H5detect.c to quiet Visual ↵Dana Robinson2013-10-191-2/+2
| | | | | | | | Studio warnings. Also added a void to a Windows-specific function. These are both trivial changes that don't affect behavior. Tested on: Visual Studio 2010 on 64-bit Windows 7
* [svn-r24171] Purpose: Fix problem with gcc 4.8Neil Fortner2013-09-191-94/+121
| | | | | | | | | | | | | | Description: With optimization enabled, gcc 4.8 inserts garbage into the padding bytes of floating point types when assigning from a literal constant. This caused problems when H5detect.c scanned the bits in floating point types to determine their properties. Modified H5detect.c to scan for padding before further analyzing the type, and to ignore all information in the padding areas. Also removed code that temporarily disabled optimization. Tested: jam, koala, ostrich, platypus (h5committest)
* [svn-r24139] Remove "will never be exectued" warnings in H5detect.cNeil Fortner2013-09-131-42/+74
| | | | Tested: jam, koala, ostrich (h5committest)
* [svn-r24098] Issue 8500 - H5detect.c has trouble to find info for long ↵Raymond Lu2013-09-041-2/+0
| | | | | | | | | double with GCC 4.8. A user in the forum found the problem in H5detect.c (uninitialized buffer) and provided the solution. I checked it in yesterday. But it turned out to be a false fix. So I'm back it out. Tested on jam - reverse of changes.
* [svn-r24095] Issue 8500 - H5detect.c has trouble to find info for long ↵Raymond Lu2013-09-031-0/+2
| | | | | | | | double with GCC 4.8. A user in the forum found the problem in H5detect.c (uninitialized buffer) and provided the solution. Allen and I verified it. Tested with h5committest and CMake on jam, koala, ostrich, playtus, and Allen's virtual machine.
* [svn-r23713] Description:Quincey Koziol2013-05-211-49/+49
| | | | | | | | | | Clean up warnings, switch library code to use Standard C/POSIX wrapper macros, remove internal calls to API routines, update checkapi and checkposix scripts. Tested on: Mac OSX/64 10.8.3 (amazon) w/C++ & FORTRAN Big-Endian Linux/64 (ostrich)
* [svn-r23048] Description:Quincey Koziol2012-11-211-11/+10
| | | | | | | | | | Bring r20456 from Coverity branch to trunk: fixed coverity 678, 679 Tested on: Mac OSX/64 10.8.2 (amazon) w/debug (too minor to require h5committest)
* [svn-r22287] Description:Quincey Koziol2012-04-161-1/+1
| | | | | | | | Clean up more FUNC_ENTER/FUNC_LEAVE macros and move H5D & H5T code toward the final design (as exemplified by the H5EA & H5FA code). Tested on: Mac OSX/64 10.7.3 (amazon) w/debug & parallel
* [svn-r21919] Description:Quincey Koziol2012-02-091-1/+1
| | | | | | | | Refactor function name macros and simplify the FUNC_ENTER macros, to clear away the cruft and prepare for further cleanups. Tested on: Mac OSX/64 10.7.3 (amazon) w/debug, production & parallel
* [svn-r20480] Description:Quincey Koziol2011-04-121-1/+1
| | | | | | | | | | | Remove global variable for the path name in the group traversal code. Also clean up a bunch of compiler warnings. Tested on: Mac OS X/32 10.6.7 (amazon) w/debug & production FreeBSD/32 6.3 (duty) w/debug FreeBSD/64 6.3 (liberty) w/debug Solaris/32 2.7 (linew) w/debug
* [svn-r18871] Description:Quincey Koziol2010-05-211-8/+8
| | | | | | | | | Clean up compiler warnings (on Windows, I hope) by marking some routines as taking 'volatile' parameters. Tested on: Mac OS X/32 10.6.3 (amazon) w/debug (too minor for h5committest)
* [svn-r18799] Description:Quincey Koziol2010-05-131-0/+3
| | | | | | | Added note about use of volatile for variables. Tested on: None - trivial change to comment.
* [svn-r18677] Just mopped up some looseends by using the macro HDxyz instead ↵Albert Cheng2010-04-291-7/+7
| | | | | | | | the xyz function names. Tested: Jam only since this is trivial.
* [svn-r18660] Description:Quincey Koziol2010-04-281-13/+19
| | | | | | | | | Tweak H5detect to be even more careful about its actions, to allow gcc 4.5 to use '-O3'. Also, minor code cleanups in H5Tfloat.c Tested on: FreeBSD/64 6.3 (liberty) w/gcc 4.5 & production mode (h5committest not necessary/appropriate)
* [svn-r18659] Bug: 1764Albert Cheng2010-04-281-65/+194
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Description: longjmp do not necessary restore signal that is blocked during the signal handling. This caused the Alignment test to fail quietly, resulting in wrong alignment information which will cause failures later. Solution: One can use sigsetjmp/siglongjmp to restore signal handling but not all systems such as Cray XT or VMS supports sigsetjmp. Backup solution is to use sigprocmask to reset the signal. Again, some systems may not support it either. Added code to try the first and then the second solution. Also added tests to verify if the signal_handler routines are working properly. Finally, added code to print results of the verification (in form of comments) to H5Tinit.c for inspection in case of failure. (Note that many platforms do not have alignment limits at all and ALIGNMNET code never raise the SIGBUS or SIGSEGV errors. In those cases, it does not matter whether the signal handlers work or not. Again, this can be deduced from the results comments near the end of the H5Tinit.c. If the sum of signal handlers called equals the total of verify, it means ALIGNMENT does not raise any signals.) For configure.in and configure: Added the test for setjmp, sigsetjmp, sigprocmask which are used by the H5detec.c. Tested: htcommittested, jam(serial).
* [svn-r18627] Description:Quincey Koziol2010-04-251-16/+8
| | | | | | | | | | | | | | | | | | | | | | | More progress toward addressing Bz#1398: add 'volatile' keyword to floating- point types when detecting their properties. Also, minor code formatting cleanups. Tested on: FreeBSD/32 6.3 (duty) in debug mode FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x, w/C++ & FORTRAN, w/threadsafe, in debug mode Linux/64-amd64 2.6 (amani) w/Intel compilers, w/default API=1.6.x, w/C++ & FORTRAN, in production mode Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN, w/szip filter, in production mode Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN, in production mode Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in debug mode Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode Mac OS X/32 10.6.3 (amazon) in debug mode Mac OS X/32 10.6.3 (amazon) w/C++ & FORTRAN, w/threadsafe, in production mode
* [svn-r18492] Bug fix:Albert Cheng2010-04-011-1/+0
| | | | | | | | | | | | | | | | | Testlibinfo.sh failed again. Solution: Removed the const from H5libhdf5_settings definition, again. Revamp the whole setting so that H5lib_settings.c is compiled individually, just like H5Tinit.c. Hope this will take care of the problem once for all. Tested: Jam using --disable-shared with --enable and --disable-embedded-libinfo. Will test this on the AIX platform after commit (cannot run bin/reconfigure in the AIX platform and it is too clumsy to try to ssh files back and forth and incurred "svn merge inconsistency" later too. Pretty confident this fix should work in all other platforms.
* [svn-r18415] Description:Quincey Koziol2010-03-181-99/+2
| | | | | | | | | | Move the libhdf5.settings information out of src/H5Tinit.c and into a separate header file (src/H5lib_settings.h), which is generated at build time (not configure time) with the src/H5make_libsettings generator program. Tested on: Linux/32 2.6 (jam) Mac OS X/32 10.6.2 (amazon)
* [svn-r18011] Description:Quincey Koziol2009-12-131-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bring Coverity changes into the trunk: (also other minor cleanups) r17991: Fix Coverity items 175 and 176. Fixed memory leak on error in print_enum in H5LT.c. r17993: (r17992 was not a Coverity change) Close Coverity issue #206: inconsistently checking whether dt->shared was non-NULL after H5T_alloc() returned a valid 'dt' value (which should guarantee that dt->shared is valid). r17994: Fix Coverity item 149. Fixed file handle leak on error in H5FD_stdio_open. r17995: Fixed Coverity issues 154 to 161: Added H5MP_close routine to error handling in the event *mp has not been freed before error. r17996: Close Coverity issue #126: potentially leaking merged_spans on routine failure. r17997: Fix Coverity items 147 and 148. Fixed resource leaks on error in H5FDloc.c. r17998: Coverity issue 269-272: Added integer result variable to functions that could return negative. Assigned to unsigned after checking. Added H5E_BEGIN_TRY block around H5Tclose and removed H5E_THROW in the catch block. Checked buffer is NULL before free. Changed HGOTO_ERROR outside of the if block to H5E_THROW. r17999: Close Coverity issue #127: release temporary spans in more generic manner. (Also add error checking to previous fix) r18000: Resolved Coverity issues 211 and 212 in H5T.c. Added comments to ignore Coverity warning regarding not checking pointer for NULL, as we are using an assert which catches the issue. r18001: Fix Coverity item 146. Fixed resource leak on error in H5O_layout_copy. r18002: Fix Coverity items 143 and 145. Fixed resource leaks on error in H5D_compact_copy and H5D_contig_copy. r18003: Close Coverity issue #192: close file on error r18004: Fix Coverity issue #125: release temporary spans on error r18005: Resolved Coverity issues 5, 25, and 83 (in H5T.c): Separated embedded functions in order to check for NULL on return of H5I_object before passing into H5T_copy. Check to see if new_dt is NULL within error handling before dereferencing it. Ignore Coverity's dead code warnings as the checks that lead to the code are machine dependent. r18006: Coverity 63,70,73: Checked result of function before assigning to an unsigned variable. r18007: Coverity 78,79: added continue statement if H5Pget_filter2 returns negative. r18008: Fixed Coverity issue # 138: Added support in error handling to free dst pointer (if allocated) on error. r18009: Whitespace & coding style cleanup
* [svn-r17838] Description:Quincey Koziol2009-11-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | Further refactoring of v2 B-tree code, moving toward being able to pass a context information to a client's encode/decode callbacks. Also, clean up of other minor compiler warnings and code formatting issues. Tested on: FreeBSD/32 6.3 (duty) in debug mode FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x, w/C++ & FORTRAN, w/threadsafe, in debug mode Linux/64-amd64 2.6 (smirom) w/Intel compilers, w/default API=1.6.x, w/C++ & FORTRAN, in production mode Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN, w/szip filter, in production mode Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN, in production mode Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in debug mode Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode Mac OS X/32 10.6.1 (amazon) in debug mode Mac OS X/32 10.6.1 (amazon) w/C++ & FORTRAN, w/threadsafe, in production mode
* [svn-r17502] Purpose:Albert Cheng2009-09-211-20/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Stage 2 implementation of embedded library information feature. H5.c: added code to print the embedded library information when there is a library versions mis-match occurs. This ensures the library information string is included in the executable. Also modifies the code so that the Library mismatch warning string is included only once in the executable. H5private.h: Added a global reference to the libinfo string variable to prepare for possible stage 3 implementation of a public API. test/testlibinfo.sh.in: A new test added to verify the library information is indeed included in the executables. configure.in: configure: Added entry to auto-generate test/testlibinfo.sh. H5detect.c: Modified the libhdf5settings generating code to allow it to insert the strings to a file other than stdout. This maybe needed in stage 3 implementation. MANIFEST: updated with the newly added file of testlibinfo.sh.in. Tested: h5committest passed. Additional tests: jam serial; jam --disable-embedded-libinfo; jam --disable-shared. All passed.
* [svn-r16829] Bug fix.Albert Cheng2009-04-211-1/+1
| | | | | | | | | | | | | | | | In Up (AIX system), the insert_libhdf5_settings() infinite looped because it never found EOF. Man getc in another system said: "If the integer value returned by getc() is stored into a variable of type char and then compared against the integer constant EOF, the com- parison may never succeed, because sign-extension of a variable of type char on widening to integer is implementation-defined." Solution: Changed inchar from type char to int fixed the problem. Morale of the story: RTFM or HTCW (heed the compiler warnings). Tested: Up (AIX 5.3).
* [svn-r16814] New feature(Bug 230):Albert Cheng2009-04-211-0/+64
| | | | | | | | | | | | | | | | | | | | | | | | Embed the content of libhdf5.settings into the hdf5 executables so that an "orphaned" executables can display (via the Unix strings command, for example) the library settings used to build the executables. This is a prototype implementation. Much improvement is needed. configure.in: Added the --disable-embedded-libinfo option to disable this feature. configure: src/H5config.h.in: Generated by autotools like automake. src/H5detect.c: Implement insert_libhdf5_settings() to insert the contents of libhdf5.settings into the library as an extern string variable so that it is included in all HDF5 executable. Much improvement is needed. fortran/src/Makefile.in: Auto-generated by bin/reconfigure. (i.e., I did make any changes to cause its direct regeneration). Tested: Jam serial, using default and --disable-embedded-libinfo, configure options.
* [svn-r16489] Fixed bug #1459 by eliminating the macro long_long and ↵Allen Byrne2009-02-181-2/+2
| | | | | | | | | | | replacing all instances with long long. Tested: h5comittest fedora 10 x64 Vista 32, VS2005, IVF101 XP32, Cygwin
* [svn-r15609] Description:Quincey Koziol2008-09-101-37/+100
| | | | | | | | Omnibus compiler warning cleanup & some reformatting also. Tested on: Mac OS X/32 10.5.4 (amazon) Too minor to require h5committest
* [svn-r15485] Purpose: Allow library to shut down properly when objects have ↵Neil Fortner2008-08-191-1/+1
| | | | | | | | | | | | | | | | reference count > 1. Description: Added a new field 'app_count' to H5I_id_info_t struct, to track the reference count on an id due to the application. the old 'count' field tracks the total. Generally any id visible to the application gets placed in app_count. Added app_ref boolean parameter to H5I_inc_ref, H5I_dec_ref, H5I_register, H5I_clear_type, and a few other functions, to specify whether the operation(s) being performed on the id(s) are due to the application (TRUE) or not (FALSE). Test added for this case. Tested: kagiso, smirom, linew (h5committest)
* [svn-r15096] Purpose: Windows Project Cleanup-- Unify Windows h5tinitScott Wegner2008-05-291-6/+0
| | | | | | | | | | Description: Previously, there was Windows-dependent code inside H5detect.c, because not all projects could access the gethostname() function. However, we standardize our project-files to link with WS2_32.lib, so now this function is available. Thus, the Windows-specific code has been removed from H5detect.c. Tested: VS2005 on WinXP VS.NET on WinXP no need to test other platforms, Windows-specific source change
* [svn-r14067] Purpose: Revise usage of H5_HAVE_SIGLONGJMPScott Wegner2007-08-101-1/+3
| | | | | | | | Description: The way I had integrated H5_HAVE_SIGLONGJMP previously, we conditionally removed far more functionality than we needed. As a result, Windows type alignment was lost. This commit localizes the ifdef so it only surrounds the actual call to siglongjmp. This is equivalent to what we've done in the past-- simply comment out the line. Tested: VNET on WinXP
* [svn-r14056] Purpose: Take advantage of new H5_HAVE_SIGLONGJMP flag in ↵Scott Wegner2007-08-081-1/+1
| | | | | | | | | | | H5detect.c Description: Visual Studio does not have the function siglongjmp. Therefore, we have created a new configure flag H5_HAVE_SIGLONGJMP that tests for this. We use this within H5detect.c. Tested: VS.NET h5committest