Changeset 8495

Show
Ignore:
Timestamp:
09/06/10 17:30:02 (3 years ago)
Author:
elaine
Message:

Partial fix to lookup problems.

Location:
branches/Orange-Elaine-Distr-Dir-Branch/src/server
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • branches/Orange-Elaine-Distr-Dir-Branch/src/server/lookup.sm

    r8492 r8495  
    642642        sizeof(PVFS_handle); 
    643643 
     644    s_op->u.lookup.err_array = (PVFS_error*)calloc(keyval_count, 
     645        sizeof(PVFS_error)); 
     646    if (s_op->u.lookup.err_array == NULL) 
     647    { 
     648        js_p->error_code = -PVFS_ENOMEM; 
     649        return SM_ACTION_COMPLETE; 
     650    } 
     651 
    644652    js_p->error_code = 0; 
    645653    ret = job_trove_keyval_read_list( 
    646         s_op->u.getattr.fs_id, s_op->u.getattr.handle, 
     654        s_op->req->u.lookup_path.fs_id, handle, 
    647655        s_op->key_a, s_op->val_a, 
    648         s_op->u.getattr.err_array, 
     656        s_op->u.lookup.err_array, 
    649657        keyval_count, 
    650658        0, 
     
    691699    s_op->u.lookup.seg_nr++; 
    692700 
     701    /* TODO: Decide which dirdata_handle is correct. Do server-to-server 
     702       communication if necessary to read the entry. */ 
    693703    ret = job_trove_keyval_read( 
    694704        s_op->req->u.lookup_path.fs_id, s_op->u.lookup.attr.u.dir.dirdata_handles[0], 
     
    787797    } 
    788798 
     799    if (s_op->u.lookup.err_array) 
     800    { 
     801        free(s_op->u.lookup.err_array); 
     802        s_op->u.lookup.err_array = NULL; 
     803    } 
     804 
    789805    /* TODO: Need to free bitmap and handles arrays. */ 
    790806 
  • branches/Orange-Elaine-Distr-Dir-Branch/src/server/pvfs2-server.h

    r8492 r8495  
    409409    PVFS_ds_attributes *ds_attr_array; 
    410410    PVFS_object_attr attr; 
     411 
     412    PVFS_error* err_array; 
    411413}; 
    412414