From eaa936b1aa25e1b18122a8ce992cd68e951105ba Mon Sep 17 00:00:00 2001 From: Manuel Reis Date: Wed, 18 Dec 2024 12:03:11 +0100 Subject: [PATCH] Dead code --- libnczarr/zsync.c | 49 ----------------------------------------------- 1 file changed, 49 deletions(-) diff --git a/libnczarr/zsync.c b/libnczarr/zsync.c index 702dbe3408..46072cfae6 100644 --- a/libnczarr/zsync.c +++ b/libnczarr/zsync.c @@ -2365,55 +2365,6 @@ insert_nczarr_attr(NCjson* jatts, NCjson* jtypes) return NC_NOERR; } -/** -Upload a .zattrs object -Optionally take control of jatts and jtypes -@param file -@param container -@param jattsp -@param jtypesp -*/ -static int -upload_attrs(NC_FILE_INFO_T* file, NC_OBJ* container, NCjson* jatts) -{ - int stat = NC_NOERR; - NCZ_FILE_INFO_T* zinfo = NULL; - NC_VAR_INFO_T* var = NULL; - NC_GRP_INFO_T* grp = NULL; - NCZMAP* map = NULL; - char* fullpath = NULL; - char* key = NULL; - - ZTRACE(3,"file=%s grp=%s",file->controller->path,grp->hdr.name); - - if(jatts == NULL) goto done; - - zinfo = file->format_file_info; - map = zinfo->map; - - if(container->sort == NCVAR) { - var = (NC_VAR_INFO_T*)container; - } else if(container->sort == NCGRP) { - grp = (NC_GRP_INFO_T*)container; - } - - /* Construct container path */ - if(container->sort == NCGRP) - stat = NCZ_grpkey(grp,&fullpath); - else - stat = NCZ_varkey(var,&fullpath); - if(stat) goto done; - - /* write .zattrs*/ - if((stat = nczm_concat(fullpath,ZATTRS,&key))) goto done; - if((stat=NCZ_uploadjson(map,key,(const NCjson*)jatts))) goto done; - nullfree(key); key = NULL; - -done: - nullfree(fullpath); - return ZUNTRACE(THROW(stat)); -} - #if 0 /** @internal Get contents of a meta object; fail it it does not exist