diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2005-08-13 20:53:35 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2005-08-13 20:53:35 (GMT) |
commit | 6b45f5172ccb4311e0be9ae15da3758abb6b0e67 (patch) | |
tree | 5a7a112fe7a8a98c6fecb45b513789d15962eb3d /c++/src/H5Attribute.cpp | |
parent | 6562465a2c2a58cfbc2f47bf60bb538f7a783933 (diff) | |
download | hdf5-6b45f5172ccb4311e0be9ae15da3758abb6b0e67.zip hdf5-6b45f5172ccb4311e0be9ae15da3758abb6b0e67.tar.gz hdf5-6b45f5172ccb4311e0be9ae15da3758abb6b0e67.tar.bz2 |
[svn-r11245] Purpose:
Code cleanup
Description:
Trim trailing whitespace, which is making 'diff'ing the two branches
difficult.
Solution:
Ran this script in each directory:
foreach f (*.[ch] *.cpp)
sed 's/[[:blank:]]*$//' $f > sed.out && mv sed.out $f
end
Platforms tested:
FreeBSD 4.11 (sleipnir)
Too minor to require h5committest
Diffstat (limited to 'c++/src/H5Attribute.cpp')
-rw-r--r-- | c++/src/H5Attribute.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/c++/src/H5Attribute.cpp b/c++/src/H5Attribute.cpp index ccfdd4c..9a177b9 100644 --- a/c++/src/H5Attribute.cpp +++ b/c++/src/H5Attribute.cpp @@ -52,7 +52,7 @@ Attribute::Attribute( const Attribute& original ) : AbstractDs( original ) {} //-------------------------------------------------------------------------- // Function: Attribute overloaded constructor -///\brief Creates an Attribute object using the id of an existing +///\brief Creates an Attribute object using the id of an existing /// attribute. ///\param existing_id - IN: Id of an existing attribute ///\exception H5::AttributeIException @@ -203,7 +203,7 @@ ssize_t Attribute::getName( size_t buf_size, string& attr_name ) const { throw AttributeIException("Attribute::getName", "H5Aget_name failed"); } - // otherwise, convert the C attribute name and return + // otherwise, convert the C attribute name and return attr_name = name_C; delete []name_C; return( name_size ); @@ -212,7 +212,7 @@ ssize_t Attribute::getName( size_t buf_size, string& attr_name ) const //-------------------------------------------------------------------------- // Function: Attribute::getName ///\brief This is an overloaded member function, provided for convenience. -/// It differs from the above function in that it returns the +/// It differs from the above function in that it returns the /// attribute's name, not the length. ///\return Name of the attribute ///\param buf_size - IN: Desired length of the name @@ -223,7 +223,7 @@ string Attribute::getName( size_t buf_size ) const { string attr_name; ssize_t name_size = getName( buf_size, attr_name ); - return( attr_name ); + return( attr_name ); // let caller catch exception if any } @@ -238,8 +238,8 @@ string Attribute::getName( size_t buf_size ) const //-------------------------------------------------------------------------- string Attribute::getName() const { - // Try with 256 characters for the name first, if the name's length - // returned is more than that then, read the name again with the + // Try with 256 characters for the name first, if the name's length + // returned is more than that then, read the name again with the // appropriate space allocation char* name_C = new char[256]; // temporary C-string for C API ssize_t name_size = H5Aget_name(id, 255, name_C); @@ -248,12 +248,12 @@ string Attribute::getName() const if (name_size >= 256) name_size = getName(name_size, attr_name); - // otherwise, convert the C attribute name and return + // otherwise, convert the C attribute name and return else attr_name = name_C; delete []name_C; - return( attr_name ); + return( attr_name ); } //-------------------------------------------------------------------------- |