Add return codes to var_set (#1543)

This commit is contained in:
mcmuffin6o 2023-08-14 09:32:04 -05:00 committed by GitHub
parent 520e8a78ff
commit 3fb82f9d84
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -551,9 +551,11 @@ int var_set_base( const char * var , T value , const char * units ) {
ref = NULL;
} else {
message_publish(MSG_WARNING,"Cannot assign to %s because io_spec does not allow input\n", var) ;
return 1;
}
} else {
message_publish(MSG_WARNING,"reference attributes not found for variable %s in call to var_set\n", var) ;
return 2;
}
return 0 ;
}