system_getgrgid(3f) - [M_system:QUERY] get groupd name associated with a GID (LICENSE:PD)
Synopsis
Description
Option
Return Value
Examples
Author
License
function system_getgrgid(gid) result (gname)
class(*),intent(in) :: gid ! any INTEGER type character(len=:),allocatable :: gname
The system_getlogin() function returns a string containing the group name associated with the given GID. If no match is found it returns a null string and sets errno to indicate the error.
gid GID to try to look up associated group for. Can be of any INTEGER type.
gname returns the group name. Blank if an error occurs
Sample program:
program demo_system_getgrgid use M_system, only : system_getgrgid use M_system, only : system_getgid implicit none character(len=:),allocatable :: name name=system_getgrgid( system_getgid() ) write(*,("group[",a,"] for ",i0))name,system_getgid() end program demo_system_getgrgidResults:
group[default] for 197121
John S. Urban
Public Domain
Nemo Release 3.1 | system_getgrgid (3m_system) | March 07, 2025 |