GetMaximumUserSpaceRestriction

Returns the maximum disk space restriction for a particular user

Local Servers:blocking
Remote Servers:blocking
NetWare Server:3.11, 3.12, 3.2, 4.x, 5.x, 6.x
Platform:NLM
SMP Aware:No
Service:Volume

Syntax

   #include <nwdir.h> 
    
    int GetMaximumUserSpaceRestriction (  
       long   trusteeID, 
       int    volume, 
       LONG   *maxRestriction);
   

Parameters

trusteeID

(IN) Specifies the desired user object ID.

volume

(IN) Specifies the desired volume (0-63 for NetWare 3.1 and later; 0-31 for previous versions).

maxRestriction

(OUT) Receives the number of 4K blocks to which the user is restricted. If this value is 0, there is no restriction.

Return Values

Value

Hex

Constant

400000000H

(0x00)

ESUCCESS

Nonzero

Invalid volume, user object ID, or network error.

Remarks

GetMaximumUserSpaceRestriction is not supported in a NetWare 2.x environment. Remote servers running NetWare 2.x return error code 251 (ERR_UNKNOWN_REQUEST).

See Also

AddTrustee, DeleteTrustee, ModifyInheritedRightsMask

Example

   #include <stdlib.h> 
    #include <nwdir.h>  
    
    main()  
    { 
       int    rc;  
       long   objectID;  
       LONG   maxRestriction; 
       rc = GetBinderyObjectID("testuser", 1, &objectID);  
       if( rc != 0)  
       {  
          printf("GetBinderyObjectID() status = %x\n", rc);  
          return;  
       }  
       rc = GetMaximumUserSpaceRestriction( objectID, 0,
            &maxRestriction);  
       if( rc != 0)  
       {  
          printf("GetMaximumUserSpaceRestriction() status = %x\n", rc);  
          return;  
       }  
       printf("Max Disk Space Restriction for ’testuser’ = %d\n",  
               maxRestriction*4096);  
    }