specframe.c | specframe.c | |||
---|---|---|---|---|
skipping to change at line 731 | skipping to change at line 731 | |||
AstSpecFrame *this; /* Pointer to the SpecFrame structure */ | AstSpecFrame *this; /* Pointer to the SpecFrame structure */ | |||
int system; /* The SpecFrame's System value */ | int system; /* The SpecFrame's System value */ | |||
/* Check the global error status. */ | /* Check the global error status. */ | |||
if ( !astOK ) return; | if ( !astOK ) return; | |||
/* Obtain a pointer to the SpecFrame structure. */ | /* Obtain a pointer to the SpecFrame structure. */ | |||
this = (AstSpecFrame *) this_frame; | this = (AstSpecFrame *) this_frame; | |||
/* Validate the axis index. */ | /* Validate the axis index. */ | |||
astValidateAxis( this, axis, "astClearUnit" ); | astValidateAxis( this, axis, 1, "astClearUnit" ); | |||
/* Clear the UsedUnit item for the current System, if current set. */ | /* Clear the UsedUnit item for the current System, if current set. */ | |||
system = (int) astGetSystem( this ); | system = (int) astGetSystem( this ); | |||
if( system < this->nuunits && this->usedunits ) { | if( system < this->nuunits && this->usedunits ) { | |||
this->usedunits[ system ] = astFree( this->usedunits[ system ] ); | this->usedunits[ system ] = astFree( this->usedunits[ system ] ); | |||
} | } | |||
/* Use the parent method to clear the Unit attribute of the axis. */ | /* Use the parent method to clear the Unit attribute of the axis. */ | |||
(*parent_clearunit)( this_frame, axis, status ); | (*parent_clearunit)( this_frame, axis, status ); | |||
} | } | |||
skipping to change at line 1576 | skipping to change at line 1576 | |||
/* Check the global error status. */ | /* Check the global error status. */ | |||
if ( !astOK ) return NULL; | if ( !astOK ) return NULL; | |||
/* Get a pointer to the structure holding thread-specific global data. */ | /* Get a pointer to the structure holding thread-specific global data. */ | |||
astGET_GLOBALS(this); | astGET_GLOBALS(this); | |||
/* Initialise. */ | /* Initialise. */ | |||
result = NULL; | result = NULL; | |||
/* Validate the axis index. */ | /* Validate the axis index. */ | |||
astValidateAxis( this, axis, "astGetLabel" ); | astValidateAxis( this, axis, 1, "astGetLabel" ); | |||
/* Check if a value has been set for the required axis label string. If so, | /* Check if a value has been set for the required axis label string. If so, | |||
invoke the parent astGetLabel method to obtain a pointer to it. */ | invoke the parent astGetLabel method to obtain a pointer to it. */ | |||
if ( astTestLabel( this, axis ) ) { | if ( astTestLabel( this, axis ) ) { | |||
result = (*parent_getlabel)( this, axis, status ); | result = (*parent_getlabel)( this, axis, status ); | |||
/* Otherwise, identify the spectral coordinate system described by the | /* Otherwise, identify the spectral coordinate system described by the | |||
SpecFrame. */ | SpecFrame. */ | |||
} else { | } else { | |||
system = astGetSystem( this ); | system = astGetSystem( this ); | |||
skipping to change at line 1825 | skipping to change at line 1825 | |||
/* Check the global error status. */ | /* Check the global error status. */ | |||
if ( !astOK ) return NULL; | if ( !astOK ) return NULL; | |||
/* Get a pointer to the structure holding thread-specific global data. */ | /* Get a pointer to the structure holding thread-specific global data. */ | |||
astGET_GLOBALS(this); | astGET_GLOBALS(this); | |||
/* Initialise. */ | /* Initialise. */ | |||
result = NULL; | result = NULL; | |||
/* Validate the axis index. */ | /* Validate the axis index. */ | |||
astValidateAxis( this, axis, "astGetSymbol" ); | astValidateAxis( this, axis, 1, "astGetSymbol" ); | |||
/* Check if a value has been set for the required axis symbol string. If so , | /* Check if a value has been set for the required axis symbol string. If so , | |||
invoke the parent astGetSymbol method to obtain a pointer to it. */ | invoke the parent astGetSymbol method to obtain a pointer to it. */ | |||
if ( astTestSymbol( this, axis ) ) { | if ( astTestSymbol( this, axis ) ) { | |||
result = (*parent_getsymbol)( this, axis, status ); | result = (*parent_getsymbol)( this, axis, status ); | |||
/* Otherwise, identify the sky coordinate system described by the SpecFrame . */ | /* Otherwise, identify the sky coordinate system described by the SpecFrame . */ | |||
} else { | } else { | |||
system = astGetSystem( this ); | system = astGetSystem( this ); | |||
skipping to change at line 2266 | skipping to change at line 2266 | |||
AstSystemType system; /* The SpecFrame's System value */ | AstSystemType system; /* The SpecFrame's System value */ | |||
const char *result; /* Pointer value to return */ | const char *result; /* Pointer value to return */ | |||
/* Check the global error status. */ | /* Check the global error status. */ | |||
if ( !astOK ) return NULL; | if ( !astOK ) return NULL; | |||
/* Obtain a pointer to the SpecFrame structure. */ | /* Obtain a pointer to the SpecFrame structure. */ | |||
this = (AstSpecFrame *) this_frame; | this = (AstSpecFrame *) this_frame; | |||
/* Validate the axis index. */ | /* Validate the axis index. */ | |||
astValidateAxis( this, axis, "astGetUnit" ); | astValidateAxis( this, axis, 1, "astGetUnit" ); | |||
/* If a value has been set for the Unit attribute, use the parent | /* If a value has been set for the Unit attribute, use the parent | |||
GetUnit method to return a pointer to the required Unit string. */ | GetUnit method to return a pointer to the required Unit string. */ | |||
if( astTestUnit( this, axis ) ){ | if( astTestUnit( this, axis ) ){ | |||
result = (*parent_getunit)( this_frame, axis, status ); | result = (*parent_getunit)( this_frame, axis, status ); | |||
/* Otherwise, identify the spectral coordinate system described by the | /* Otherwise, identify the spectral coordinate system described by the | |||
SpecFrame. */ | SpecFrame. */ | |||
} else { | } else { | |||
system = astGetSystem( this ); | system = astGetSystem( this ); | |||
skipping to change at line 4199 | skipping to change at line 4199 | |||
int i; /* Loop counter */ | int i; /* Loop counter */ | |||
int system; /* The SpecFrame's System value */ | int system; /* The SpecFrame's System value */ | |||
/* Check the global error status. */ | /* Check the global error status. */ | |||
if ( !astOK ) return; | if ( !astOK ) return; | |||
/* Obtain a pointer to the SpecFrame structure. */ | /* Obtain a pointer to the SpecFrame structure. */ | |||
this = (AstSpecFrame *) this_frame; | this = (AstSpecFrame *) this_frame; | |||
/* Validate the axis index. */ | /* Validate the axis index. */ | |||
astValidateAxis( this, axis, "astSetUnit" ); | astValidateAxis( this, axis, 1, "astSetUnit" ); | |||
/* Store the supplied value as the UsedUnit for the current System. First | /* Store the supplied value as the UsedUnit for the current System. First | |||
ensure the array is big enough. Free any previous value stored for the | ensure the array is big enough. Free any previous value stored for the | |||
current system. */ | current system. */ | |||
system = (int) astGetSystem( this ); | system = (int) astGetSystem( this ); | |||
if( system >= this->nuunits ) { | if( system >= this->nuunits ) { | |||
this->usedunits = astGrow( this->usedunits, system + 1, | this->usedunits = astGrow( this->usedunits, system + 1, | |||
sizeof(char *) ); | sizeof(char *) ); | |||
if( astOK ) { | if( astOK ) { | |||
for( i = this->nuunits; i < system + 1; i++ ) this->usedunits[ i ] = NULL; | for( i = this->nuunits; i < system + 1; i++ ) this->usedunits[ i ] = NULL; | |||
End of changes. 5 change blocks. | ||||
5 lines changed or deleted | 5 lines changed or added | |||
This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/ |