⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 getlogin.3

📁 Unix操作系统minix 2.0源码
💻 3
字号:
.\"	@(#)getlogin.3	6.2 (Berkeley) 5/9/86.\".TH GETLOGIN 3  "May 9, 1986".AT 3.SH NAMEgetlogin \- get login name.SH SYNOPSIS.nf.ft B#include <unistd.h>char *getlogin(void).fi.SH DESCRIPTION.B Getloginreturns a pointer to the login name as found in.BR /etc/utmp .It may be used in conjunction with.B getpwnamto locate the correct password file entry when the same user IDis shared by several login names..PPIf.B getloginis called within a process that is not attached to aterminal, or if there is no entry in.B /etc/utmpfor the process's terminal,.B getloginreturns a null pointer.A reasonable procedure for determining the login name is to first call.B getloginand if it fails, to call.BR getpwuid ( getuid ())..SH FILES/etc/utmp.SH "SEE ALSO".BR getpwent (3),.BR utmp (5),.BR ttyslot (3).SH DIAGNOSTICSReturns a null pointer if the name cannot be found..SH BUGSThe return values point to static datawhose content is overwritten by each call.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -