"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "plugins/rule_engines/irods_rule_engine_plugin-irods_rule_language/reStruct.cpp" between
irods-4.2.5.tar.gz and irods-4.2.6.tar.gz

About: iRODS (the integrated Rule Oriented Data System) is a distributed data-management system for creating data grids, digital libraries, persistent archives, and real-time data systems.

reStruct.cpp  (irods-4.2.5):reStruct.cpp  (irods-4.2.6)
/*** Copyright (c), The Regents of the University of California *** /*** Copyright (c), The Regents of the University of California ***
*** For more information please refer to files in the COPYRIGHT directory ***/ *** For more information please refer to files in the COPYRIGHT directory ***/
#include "reGlobalsExtern.hpp" #include "irods_re_structs.hpp"
#include "reFuncDefs.hpp"
#include "rcMisc.h" #include "rcMisc.h"
#include "objMetaOpr.hpp" #include "objMetaOpr.hpp"
#include "resource.hpp" #include "resource.hpp"
// =-=-=-=-=-=-=- // =-=-=-=-=-=-=-
#include "irods_resource_backport.hpp" #include "irods_resource_backport.hpp"
void *mallocAndZero( int s ) { void *mallocAndZero( int s ) {
void *t; void *t;
t = malloc( s ); t = malloc( s );
skipping to change at line 99 skipping to change at line 98
to->next = ( ruleExecInfo_t* )mallocAndZero( sizeof( ruleExecInfo_t ) ); to->next = ( ruleExecInfo_t* )mallocAndZero( sizeof( ruleExecInfo_t ) );
copyRuleExecInfo( from->next, to->next ); copyRuleExecInfo( from->next, to->next );
} }
else { else {
to->next = NULL; to->next = NULL;
} }
return 0; return 0;
} }
int int
freeRuleExecInfoStruct( ruleExecInfo_t *rs, int freeSpeialStructFlag ) { freeRuleExecInfoStruct( ruleExecInfo_t *rs, int freeSpecialStructFlag ) {
freeRuleExecInfoInternals( rs, freeSpeialStructFlag ); freeRuleExecInfoInternals( rs, freeSpecialStructFlag );
free( rs ); free( rs );
return 0; return 0;
} }
int int
freeRuleExecInfoInternals( ruleExecInfo_t *rs, int freeSpeialStructFlag ) { freeRuleExecInfoInternals( ruleExecInfo_t *rs, int freeSpecialStructFlag ) {
if ( rs->msParamArray != NULL && ( freeSpeialStructFlag & FREE_MS_PARAM ) > if ( rs->msParamArray != NULL && ( freeSpecialStructFlag & FREE_MS_PARAM ) >
0 ) { 0 ) {
clearMsParamArray( rs->msParamArray, 1 ); clearMsParamArray( rs->msParamArray, 1 );
free( rs->msParamArray ); free( rs->msParamArray );
} }
if ( rs->doinp != NULL && ( freeSpeialStructFlag & FREE_DOINP ) > 0 ) { if ( rs->doinp != NULL && ( freeSpecialStructFlag & FREE_DOINP ) > 0 ) {
clearDataObjInp( rs->doinp ); clearDataObjInp( rs->doinp );
free( rs->doinp ); free( rs->doinp );
} }
if ( rs->doi != NULL ) { if ( rs->doi != NULL ) {
freeAllDataObjInfo( rs->doi ); freeAllDataObjInfo( rs->doi );
} }
if ( rs->uoic != NULL ) { if ( rs->uoic != NULL ) {
freeUserInfo( rs->uoic ); freeUserInfo( rs->uoic );
} }
skipping to change at line 135 skipping to change at line 134
if ( rs->coi != NULL ) { if ( rs->coi != NULL ) {
freeCollInfo( rs->coi ); freeCollInfo( rs->coi );
} }
if ( rs->uoio != NULL ) { if ( rs->uoio != NULL ) {
freeUserInfo( rs->uoio ); freeUserInfo( rs->uoio );
} }
if ( rs->condInputData != NULL ) { if ( rs->condInputData != NULL ) {
freeKeyValPairStruct( rs->condInputData ); freeKeyValPairStruct( rs->condInputData );
} }
if ( rs->next != NULL ) { if ( rs->next != NULL ) {
freeRuleExecInfoStruct( rs->next, freeSpeialStructFlag ); freeRuleExecInfoStruct( rs->next, freeSpecialStructFlag );
} }
return 0; return 0;
} }
int int
copyDataObjInfo( dataObjInfo_t *from, dataObjInfo_t *to ) { copyDataObjInfo( dataObjInfo_t *from, dataObjInfo_t *to ) {
*to = *from; *to = *from;
if ( from->next != NULL ) { if ( from->next != NULL ) {
to->next = ( dataObjInfo_t* )mallocAndZero( sizeof( dataObjInfo_t ) ); to->next = ( dataObjInfo_t* )mallocAndZero( sizeof( dataObjInfo_t ) );
copyDataObjInfo( from->next, to->next ); copyDataObjInfo( from->next, to->next );
 End of changes. 5 change blocks. 
9 lines changed or deleted 8 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)