By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,191 Members | 790 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,191 IT Pros & Developers. It's quick & easy.

File pointeur of stdout

P: n/a
Hello ,

I write a program that require the users to enter their password. How to do it?
According to a book of K&R, "When a program begins execution, three stream stdin,
stdout, stderr are already open". But how to get pointers to these stream?

Faithfully yours,
Try.
Nov 14 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
In article <7f*************************@posting.google.com> ,
Try Kret <kr*****@kh.refer.org> wrote:
Hello ,

I write a program that require the users to enter their password. How to do it?
According to a book of K&R, "When a program begins execution, three
stream stdin,
stdout, stderr are already open". But how to get pointers to these stream?


stdin, stdout, and stderr *are* file pointers to the standard input,
standard output, and standard error streams. Try reading up on functions
such as getchar, fgets, etc.

-Tim Miller
Nov 14 '05 #2

P: n/a
Tim Miller wrote:
In article <7f*************************@posting.google.com> ,
Try Kret <kr*****@kh.refer.org> wrote:
Hello ,

I write a program that require the users to enter their password. How to do it?
According to a book of K&R, "When a program begins execution, three
stream stdin,
stdout, stderr are already open". But how to get pointers to these stream?

stdin, stdout, and stderr *are* file pointers to the standard input,
standard output, and standard error streams.


But you do have to #include <stdio.h> in order to get the declarations
for them.

-Kevin
--
My email address is valid, but changes periodically.
To contact me please use the address from a recent posting.
Nov 14 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.