Index: /trunk/indexers/mgpp/jni/MGPPWrapperImpl.cpp
===================================================================
--- /trunk/indexers/mgpp/jni/MGPPWrapperImpl.cpp	(revision 4236)
+++ /trunk/indexers/mgpp/jni/MGPPWrapperImpl.cpp	(revision 4237)
@@ -78,10 +78,10 @@
   FID_mgpp_data = j_env->GetFieldID(j_cls, "mgpp_data_ptr_", "J"); //a long-"J"
   if (FID_mgpp_data==NULL) {
-      cerr <<"field mgpp_data_ptr_ not found"<<endl;
+      cerr <<"MGPP JNI: field mgpp_data_ptr_ not found"<<endl;
   } 
 
   FID_query_result = j_env->GetFieldID(j_cls, "mgpp_query_result_", "Lorg/greenstone/mgpp/MGPPQueryResult;"); // an object -"L<class name>;"
   if (FID_query_result==NULL) {
-      cerr <<"field mgpp_query_result_ not found"<<endl;
+      cerr <<"MGPP JNI: field mgpp_query_result_ not found"<<endl;
   }
   // the methods we want to use
@@ -91,5 +91,5 @@
   MID_addDoc = j_env->GetMethodID(JC_MGPPQueryResult, "addDoc", "(JF)V");
   if (MID_addDoc==NULL) {
-      cerr <<"method not found"<<endl;
+      cerr <<"MGPP JNI: addDoc method not found"<<endl;
   }
   // addTerm(String term, String tag, int stem_method, long match_docs, 
@@ -97,5 +97,5 @@
   MID_addTerm = j_env->GetMethodID(JC_MGPPQueryResult, "addTerm", "(Ljava/lang/String;Ljava/lang/String;IJJ[Ljava/lang/String;)V");
   if (MID_addTerm==NULL) {
-      cerr <<"method addTerm not found"<<endl;
+      cerr <<"MGPP JNI: method addTerm not found"<<endl;
   }
   
@@ -103,14 +103,14 @@
   MID_setTotalDocs = j_env->GetMethodID(JC_MGPPQueryResult, "setTotalDocs", "(J)V");
   if (MID_setTotalDocs==NULL) {
-      cerr <<"method setTotalDocs not found"<<endl;
+      cerr <<"MGPP JNI: method setTotalDocs not found"<<endl;
   }
   
   MID_clearResult = j_env->GetMethodID(JC_MGPPQueryResult, "clear", "()V");
   if (MID_clearResult==NULL) {
-      cerr <<"method clear not found"<<endl;
+      cerr <<"MGPP JNI: method clear not found"<<endl;
   }
   MID_setSyntaxError = j_env->GetMethodID(JC_MGPPQueryResult, "setSyntaxError", "(Z)V");
   if (MID_clearResult==NULL) {
-      cerr <<"method setSyntaxError not found"<<endl;
+      cerr <<"MGPP JNI: method setSyntaxError not found"<<endl;
   }
 
@@ -119,5 +119,5 @@
   jclass local_CID_String = j_env->FindClass("java/lang/String");
   if (local_CID_String==NULL) {
-    cerr <<"java String class not found"<<endl;
+    cerr <<"MGPP JNI: java String class not found"<<endl;
   } else { 
     /* create a global ref */
@@ -164,6 +164,4 @@
 #endif
 
-  cerr << "Doing getDocument..." << endl;
-
   const char * text_name = j_env->GetStringUTFChars(j_text_name, NULL);
   if (text_name==NULL) {
@@ -182,7 +180,5 @@
 
   // cast to char* otherwise complains about const
-  cerr << "(MGPP JNI) Base dir: " << base_dir << " Text name: " << text_name << endl;
   td.LoadData((char *)base_dir, (char *)text_name);
-  cerr << "Done loadData." << endl;
 
   UCArray mg_level;
@@ -192,5 +188,5 @@
   // get the actual text
   if (!GetDocText(td, mg_level, docnum, docText)) {
-    cerr <<"couldn't retrieve doc text"<<endl;
+    cerr <<"MGPP JNI: couldn't retrieve doc text"<<endl;
   }
 
Index: /trunk/mgpp/jni/MGPPWrapperImpl.cpp
===================================================================
--- /trunk/mgpp/jni/MGPPWrapperImpl.cpp	(revision 4236)
+++ /trunk/mgpp/jni/MGPPWrapperImpl.cpp	(revision 4237)
@@ -78,10 +78,10 @@
   FID_mgpp_data = j_env->GetFieldID(j_cls, "mgpp_data_ptr_", "J"); //a long-"J"
   if (FID_mgpp_data==NULL) {
-      cerr <<"field mgpp_data_ptr_ not found"<<endl;
+      cerr <<"MGPP JNI: field mgpp_data_ptr_ not found"<<endl;
   } 
 
   FID_query_result = j_env->GetFieldID(j_cls, "mgpp_query_result_", "Lorg/greenstone/mgpp/MGPPQueryResult;"); // an object -"L<class name>;"
   if (FID_query_result==NULL) {
-      cerr <<"field mgpp_query_result_ not found"<<endl;
+      cerr <<"MGPP JNI: field mgpp_query_result_ not found"<<endl;
   }
   // the methods we want to use
@@ -91,5 +91,5 @@
   MID_addDoc = j_env->GetMethodID(JC_MGPPQueryResult, "addDoc", "(JF)V");
   if (MID_addDoc==NULL) {
-      cerr <<"method not found"<<endl;
+      cerr <<"MGPP JNI: addDoc method not found"<<endl;
   }
   // addTerm(String term, String tag, int stem_method, long match_docs, 
@@ -97,5 +97,5 @@
   MID_addTerm = j_env->GetMethodID(JC_MGPPQueryResult, "addTerm", "(Ljava/lang/String;Ljava/lang/String;IJJ[Ljava/lang/String;)V");
   if (MID_addTerm==NULL) {
-      cerr <<"method addTerm not found"<<endl;
+      cerr <<"MGPP JNI: method addTerm not found"<<endl;
   }
   
@@ -103,14 +103,14 @@
   MID_setTotalDocs = j_env->GetMethodID(JC_MGPPQueryResult, "setTotalDocs", "(J)V");
   if (MID_setTotalDocs==NULL) {
-      cerr <<"method setTotalDocs not found"<<endl;
+      cerr <<"MGPP JNI: method setTotalDocs not found"<<endl;
   }
   
   MID_clearResult = j_env->GetMethodID(JC_MGPPQueryResult, "clear", "()V");
   if (MID_clearResult==NULL) {
-      cerr <<"method clear not found"<<endl;
+      cerr <<"MGPP JNI: method clear not found"<<endl;
   }
   MID_setSyntaxError = j_env->GetMethodID(JC_MGPPQueryResult, "setSyntaxError", "(Z)V");
   if (MID_clearResult==NULL) {
-      cerr <<"method setSyntaxError not found"<<endl;
+      cerr <<"MGPP JNI: method setSyntaxError not found"<<endl;
   }
 
@@ -119,5 +119,5 @@
   jclass local_CID_String = j_env->FindClass("java/lang/String");
   if (local_CID_String==NULL) {
-    cerr <<"java String class not found"<<endl;
+    cerr <<"MGPP JNI: java String class not found"<<endl;
   } else { 
     /* create a global ref */
@@ -164,6 +164,4 @@
 #endif
 
-  cerr << "Doing getDocument..." << endl;
-
   const char * text_name = j_env->GetStringUTFChars(j_text_name, NULL);
   if (text_name==NULL) {
@@ -182,7 +180,5 @@
 
   // cast to char* otherwise complains about const
-  cerr << "(MGPP JNI) Base dir: " << base_dir << " Text name: " << text_name << endl;
   td.LoadData((char *)base_dir, (char *)text_name);
-  cerr << "Done loadData." << endl;
 
   UCArray mg_level;
@@ -192,5 +188,5 @@
   // get the actual text
   if (!GetDocText(td, mg_level, docnum, docText)) {
-    cerr <<"couldn't retrieve doc text"<<endl;
+    cerr <<"MGPP JNI: couldn't retrieve doc text"<<endl;
   }
 
