setgrent (BPX1SGE, BPX4SGE) — Reset the group database

Function

The setgrent callable service resets the group database for subsequent searching by the getgrent service. The next getgrent service that is used after setgrent starts searching from the beginning of the group database.

Requirements

Operation Environment
Authorization: Supervisor state or problem state, any PSW key
Dispatchable unit mode: Task
Cross memory mode: PASN = HASN
AMODE (BPX1SGE): 31-bit
AMODE (BPX4SGE): 64-bit
ASC mode: Primary mode
Interrupt status: Enabled for interrupts
Locks: Unlocked
Control parameters: All parameters must be addressable by the caller and in the primary address space.

Format

CALL BPX1SGE,(Return_value)

AMODE 64 callers use BPX4SGE.

Parameters

Return_value
Returned parameter
Type:
Integer
Length:
Fullword

The name of a fullword in which the setgrent service returns 0.

Usage notes

The setgrent service is intended to be used to interrupt a sequential search of the group database from the calling task. The getgrent service performs the sequential search. When the setgrent service is called, it resets the search point for the current task in the group database to the beginning. The next getgrent service that is called from this task after this point starts searching the group database from the beginning.

Related services

Characteristics and restrictions

There are no restrictions on the use of the setgrent service.

Examples

For an example using this callable service, see BPX1SGE (setgrent) example.