*** empty log message ***

This commit is contained in:
koennecke
2007-11-27 13:36:15 +00:00
parent 1265ae957b
commit 22b0e8ec83
50 changed files with 6025 additions and 171 deletions

View File

@@ -401,7 +401,7 @@ hdbValue MakeHdbIntArray(int length, int *data){
return result;
}
/*-------------------------------------------------------------------------*/
hdbValue MakeHdbFloatArrray(int length, double *data){
hdbValue MakeHdbFloatArray(int length, double *data){
hdbValue result;
result.dataType = HIPFLOATAR;
@@ -411,6 +411,10 @@ hdbValue MakeHdbFloatArrray(int length, double *data){
}
/*-------------------------------------------------------------------------*/
void ReleaseHdbValue(hdbValue *v){
if(v->doNotFree == 1){
return;
}
switch(v->dataType){
case HIPTEXT:
if(v->v.text != NULL){
@@ -871,10 +875,30 @@ void InternalRemoveHipadabaCallback(pHdb root, int internalID){
}
}
/*=================== parameter interface ====================================*/
static int canCopy(hdbValue *source, hdbValue *target){
if(target->dataType == HIPINTVARAR) {
if(source->dataType == HIPINTAR ||
source->dataType == HIPINTVARAR){
return 1;
}
}
if(target->dataType == HIPFLOATVARAR) {
if(source->dataType == HIPFLOATAR ||
source->dataType == HIPFLOATVARAR){
return 1;
}
}
if(source->dataType != target->dataType){
return 0;
} else {
return 1;
}
}
/*----------------------------------------------------------------------------*/
int copyHdbValue(hdbValue *source, hdbValue *target){
int i;
if(source->dataType != target->dataType){
if(!canCopy(source,target)){
return 0;
}