Commit 340757fd authored by Ryan Berkheimer's avatar Ryan Berkheimer

bugfixin

parent e39c388d
......@@ -90,7 +90,7 @@ ifeq ($(UNAME), Darwin)
LNFLAGS=-dynamiclib -shared -lgfortran -I$(JVMHEADERS) -framework JavaVM
endif
CFLAGS=-I$(JVMHEADERS) -I$(COMMONCPPPATH) -I$(COMMONCPATH) -I$(USERCPPPATH) -I$(USERCPATH) -I$(JNIDIR) -I$(JNIMDDIR) -fpic -std=c99
CFLAGS=-I$(JVMHEADERS) -I$(COMMONCPPPATH) -I$(COMMONCPATH) -I$(USERCPPPATH) -I$(USERCPATH) -I$(JNIDIR) -I$(JNIMDDIR) -fpic# -std=c99
FFLAGS=-I$(COMMONFORTRANPATH) -I$(USERFORTRANPATH) -fPIC -fopenmp
#The following is the target library for the native jni library.
......
......@@ -23,7 +23,8 @@ JNIEXPORT jobject JNICALL Java_gov_noaa_messageapi_endpoints_NativeEndpoint_proc
struct string_list* default_field_name_list = getFieldIds(message, getRecord(message, default_record_list, 0));
printf("Field name count: %d\n", default_field_name_list->count);
printf("Length of longest field name: %d\n", default_field_name_list->max_length);
for (int i = 0; i < default_field_name_list->count; i++) {
int i;
for (i = 0; i < default_field_name_list->count; i++) {
printf("Field name: %s\n", default_field_name_list->strings[i]);
}
fflush(stdout);
......@@ -57,7 +58,7 @@ JNIEXPORT jobject JNICALL Java_gov_noaa_messageapi_endpoints_NativeEndpoint_proc
printf("Field string value 2 is: %s\n", stringFieldValue);
struct val_list *val_list = getFieldListVal(message, testField3);
printf("Field value 3 (list) length is: %d\n", val_list->count);
for (int i = 0; i < val_list->count; i++) {
for (i = 0; i < val_list->count; i++) {
printf("Field value 3, element %d, is: %d\n", i, getIntEntry(message, val_list, i));
}
fflush(stdout);
......@@ -70,7 +71,7 @@ JNIEXPORT jobject JNICALL Java_gov_noaa_messageapi_endpoints_NativeEndpoint_proc
struct record *returnRecord = createRecord(message);
struct string_list *fieldIds = getFieldIds(message, returnRecord);
printf("field ids for return field follow. \n");
for (int i=0; i < fieldIds->count; i++) {
for (i=0; i < fieldIds->count; i++) {
printf("Field name: %s\n", fieldIds->strings[i]);
if (getFieldIsNull(message, getField(message, returnRecord,fieldIds->strings[i])))
{
......
......@@ -541,7 +541,7 @@ jobject MessageApiEndpoint::getProtocolRecords(const char* method, const char* k
struct record_list * MessageApiEndpoint::getRecords(const char *recordMethod, const char *key, const char *val)
{
jobject jprotocolRecords = this->getProtocolRecords(recordMethod, key, val);
printf("Received jProtocolRecords.");
printf("Received jProtocolRecords.\n");
fflush(stdout);
int recordCount = this->getJListLength(jprotocolRecords);
struct record_list *record_list = (struct record_list *) malloc(sizeof(struct record_list));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment