status = RtlQueryRegistryValues(
RTL_REGISTRY_ABSOLUTE,
parameter_path.Buffer,
&query_table[0],
NULL,
NULL
);
返回0

解决方案 »

  1.   

    RtlQueryRegistryValues returns an NTSTATUS code. The possible return values include:STATUS_SUCCESS 
    The entire query table was processed successfully.
     
    STATUS_INVALID_PARAMETER 
    Processing of the query table terminated with an invalid table entry. A table entry can be invalid if the specified flags require the QueryRoutine or Name members to be non-NULL, but a NULL value was provided. STATUS_OBJECT_NAME_NOT_FOUND 
    The Path parameter does not match a valid key, or processing of the query table terminated with an entry with the RTL_QUERY_REGISTRY_REQUIRED flag set and no matching key is found. This occurs if the Name member is NULL and the current key has no subkeys, or if Name specifies a nonexistent subkey. STATUS_BUFFER_TOO_SMALL 
    The RTL_QUERY_REGISTRY_DIRECT flag is set, and the buffer specified by EntryContext is too small to hold the key value data. RtlQueryRegistryValues also terminates processing of the table if the QueryRoutine function for a table entry returns an NTSTATUS error code, and returns that error code as its result. (With one exception: If QueryRoutine returns STATUS_BUFFER_TOO_SMALL, the error code is ignored.)
      

  2.   

    #define STATUS_SUCCESS ((NTSTATUS)0x00000000L) // ntsubauth