Special case for '/' group in h5_create_group.
authorW. Trevor King <wking@drexel.edu>
Wed, 20 Apr 2011 20:31:56 +0000 (16:31 -0400)
committerW. Trevor King <wking@drexel.edu>
Wed, 20 Apr 2011 20:31:56 +0000 (16:31 -0400)
pypiezo/config.py

index 1e182b4645ec600e0784fbd4a5bfc658b3a8d25b..6df2460dbda02c57bd57c09eb066ab058e2c6838 100644 (file)
@@ -463,6 +463,8 @@ def _pformat_hdf5(cwg, depth=0):
                          
 def h5_create_group(cwg, path):
     "Create the group where the settings are stored (if necessary)."
+    if path == '/':
+        return cwg
     gpath = ['']
     for group in path.strip('/').split('/'):
         gpath.append(group)