Project

Profile

Help

Revision 00082f6f

Added by O'Neil Delpratt 5 months ago

Saxon/C bug fixes

View differences:

src/main/c/Saxon.C.API/SaxonCGlue.c
272 272

  
273 273
	MID_init = (*penv)->GetMethodID(penv, myClassInDll, "<init>", "()V");
274 274
	if (!MID_init) {
275
		printf("Error: MyClassInDll.<init>() not found\n");
275
		printf("Error: SaxoncDll.%s <init>() not found\n", name);
276 276
		return;
277 277
	}
278 278

  
279 279
	obj = (*penv)->NewObject(penv, myClassInDll, MID_init);
280 280
	if (!obj) {
281
		printf("Error: failed to allocate an object\n");
281
		printf("Error: failed to allocate an object - please check if an exception was thrown\n");
282 282
		return;
283 283
	}
284 284

  
......
321 321

  
322 322
	MID_initj = (jmethodID)(*penv)->GetMethodID(penv, myClassInDll, "<init>", arguments);
323 323
	if (!MID_initj) {
324
		printf("Error: MyClassInDll.<init>() not found\n");
324
		printf("Error: SaxoncDll.<init>() not found\n");
325 325
		fflush(stdout);
326 326
		return 0;
327 327
	}
......
340 340

  
341 341
	MID_initi = (jmethodID)(*(penv))->GetMethodID(penv, myClassInDll, "<init>", arguments);
342 342
	if (!MID_initi) {
343
		printf("Error: MyClassInDll.<init>() not found\n");
343
		printf("Error: SaxoncDll.<init>() not found\n");
344 344
		return NULL;
345 345
	}
346 346

  
......
353 353
		obj = (jobject)(*(penv))->NewObject(penv, myClassInDll, MID_initi, license);
354 354
	}
355 355
	if (!obj) {
356
		printf("Error: failed to allocate an object\n");
356
		printf("Error: failed to allocate an object - please check if an exception was thrown\n");
357 357
		return NULL;
358 358
	}
359 359
	return obj;
......
371 371

  
372 372
	MID_initi = (jmethodID)(*(penv))->GetMethodID(penv, myClassInDll, "<init>", arguments);
373 373
	if (!MID_initi) {
374
		printf("Error: MyClassInDll.<init>() not found\n");
374
		printf("Error: SaxoncDll.<init>() not found\n");
375 375
		return NULL;
376 376
	}
377 377

  
......
384 384
		obj = (jobject)(*(penv))->NewObject(penv, myClassInDll, MID_initi);
385 385
	}
386 386
	if (!obj) {
387
		printf("Error: failed to allocate an object\n");
387
		printf("Error: failed to allocate an object - please check if an exception was thrown\n");
388 388
		return NULL;
389 389
	}
390 390
	return obj;

Also available in: Unified diff