VMS Help  —  CRTL  Shared Memory Routines, shmctl  Return Values
    0                 Successful completion.

    -1                Indicates an error. The function sets errno to one
                      of the following values:

                      o  EACCES - The argument cmd is equal to IPC_STAT
                         and the calling process does not have read
                         permission.

                      o  EINVAL - The value of shmid is not a valid
                         shared memory identifier, or the value of cmd
                         is not a valid command.

                      o  EFAULT - The argument cmd has value IPC_SET
                         but the address pointed to by buf is not
                         accessible.

                      o  EPERM - The argument cmd is equal to IPC_RMID
                         or IPC_SET and the effective user ID of the
                         calling process is not equal to that of a
                         process with appropriate privileges and it is
                         not equal to the value of shm_perm.cuid or
                         shm_perm.uid in the data structure associated
                         with shmid.

                      o  EVMSERR - OpenVMS specific non-translatable
                         error code.
Close Help