harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vera Petrashkova (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-4339) [buildtest][vts] Test vm/jvmti/funcs/AddToBootCLSearch/AddToBootCLSearch0102/AddToBootCLSearch0102.xml is incorrect
Date Wed, 04 Jul 2007 12:52:04 GMT
[buildtest][vts] Test vm/jvmti/funcs/AddToBootCLSearch/AddToBootCLSearch0102/AddToBootCLSearch0102.xml
is incorrect

                 Key: HARMONY-4339
                 URL: https://issues.apache.org/jira/browse/HARMONY-4339
             Project: Harmony
          Issue Type: Bug
          Components: build - test - ci
            Reporter: Vera Petrashkova
            Priority: Minor

According to J2SE JVMTI specification:
   AddToBootstrapClassLoaderSearch(jvmtiEnv* env, const char* segment)
   After the bootstrap class loader unsuccessfully searches for a class, 
   the specified platform-dependent search path segment will be searched as well. 

    This method returns JVMTI_ERROR_ILLEGAL_ARGUMENT if segment is an invalid path.

VTS test 
is incorrect It bases on the wrong assumption that VM returns JVMTI_ERROR_ILLEGAL_ARGUMENT
when used path is absent. 
See source code:
    Callbacks CB;
    jvmtiEvent events[] = {JVMTI_EVENT_VM_DEATH };
    jvmtiEnv *jvmti;
    jvmtiError result;

#ifdef LINUX
    const char* path = "/there/is/not/such/path/.";              <<<<<<<<<<<<<
correct path which does not exist
    const char* path = "c:\\there\\is\\not\\such\\path\\.";     <<<<<<<<<<<<<
correct path which does not exist
    jint res = func_for_Agent_OnLoad_JVMTI(vm, options, reserved, &CB,
        events, sizeof(events)/4, test_case_name, DEBUG_OUT, &jvmti);

    util = true;

    result = jvmti->AddToBootstrapClassLoaderSearch(path);
    fprintf(stderr, "\tnative: AddToBootstrapClassLoaderSearch result = %d (must be JVMTI_ERROR_ILLEGAL_ARGUMENT
(103)) \n", result);
    if (result == JVMTI_ERROR_ILLEGAL_ARGUMENT) test = true;

    return res;

void JNICALL callbackVMDeath(prms_VMDEATH)
    func_for_callback_VMDeath(jni_env, jvmti_env, test_case_name, test, util);

This test fails on RI.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message