Project

Profile

Help

Revision 0608038f

Added by O'Neil Delpratt over 5 years ago

Bug fix relating to issue 2772

View differences:

latest9.6/hec/Saxon.C.API/XdmValue.cpp
33 33
		values.clear();
34 34
		if(valueType != NULL) {delete valueType;}
35 35
		if(jValues && proc != NULL) {
36
			proc->environ->env->DeleteLocalRef(jValues);
36
			environ->env->DeleteLocalRef(jValues);
37 37
		}
38 38
		xdmSize=0;
39 39
	}
......
73 73
			proc = proci;	
74 74
			jValues;
75 75
			int i;
76
			JNIEnv *env = proc->environ->env;
76
			JNIEnv *env = environ->env;
77 77
			int count = values.size();
78 78
			if(count == 0) {
79 79
				return NULL;
......
98 98
	XdmItem * XdmValue::itemAt(int n){
99 99
		/*if(jValues != NULL) {
100 100
			values.clear();
101
			int sizex = proc->environ->env->GetArrayLength(jvalues);
101
			int sizex = environ->env->GetArrayLength(jvalues);
102 102
			for (int p=0; p < sizex; ++p) 
103 103
			{
104
				jobject resulti = proc->environ->env->GetObjectArrayElement(jValues, p);
104
				jobject resulti = environ->env->GetObjectArrayElement(jValues, p);
105 105
				values->addUnderlyingValue(resulti);
106 106
			}
107
			proc->environ->env->DeleteLocalRef(jValues);
107
			environ->env->DeleteLocalRef(jValues);
108 108
			jValues = NULL;
109 109
		}*/
110 110
		if(n >= 0 && n< values.size()) {

Also available in: Unified diff