home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
GEMini Atari
/
GEMini_Atari_CD-ROM_Walnut_Creek_December_1993.iso
/
zip
/
mint
/
mntlib16.lzh
/
MNTLIB16
/
GETPASS.C
< prev
next >
Wrap
C/C++ Source or Header
|
1993-08-03
|
330b
|
21 lines
#include <ioctl.h>
#include <stdio.h>
char *
getpass(str)
char *str;
{
static char buf[80];
struct sgttyb oldsb, newsb;
gtty(0, &oldsb);
newsb = oldsb;
newsb.sg_flags &= ~ECHO;
stty(0, &newsb);
fputs(str, stderr); fflush(stderr);
buf[0] = 0;
fgets(buf, 80, stdin);
stty(0, &oldsb);
return buf;
}