函式功能
函式名: isatty
功 能: 檢查設備類型
用 法: int isatty(int handle);
程式示例
#include
#include
int main(void)
{
int handle;
handle = fileno(stdprn);
if (isatty(handle))
printf("Handle %d is a device type\n", handle);
else
printf("Handle %d isn't a device type\n", handle);
return 0;
}