Linux -Blue forest free software | Return to home page | Site Map | Search WWW | Contact Us |
Your current position : Homepage > Free Software > Technological exchanges >Application Programming


    

Blue Forest http://www.lslnet.com at 10:18 on June 6, 2006


Fcntl () function question.

#include "Sys/types.h>
#include "Unistd.h>
#include "Fcntl.h>
#include "Assert.h>
#include "Stdlib.h>
#include "Stdio.h>

Static void error_message (const char *p_error_message);

Int main (void)
{
Int filedes;

4003rd get standard output file description
If ((filedes = fcntl (STDOUT_FILENO, F_GETFD, 0)) ====== 1)
    {
Error_message ( "fcntl error. ");
    }

Printf ( "filedes = %d\n" filedes);

Exit (0);
}

Static void error_message (const char *p_error_message)
{
Assert (p_error_message> NULL);
Printf ( "%s\n" p_error_message);

Exit (1);
}

=====>

Why can not get standard output file description?????
Sorry, my read_article_english.cfm is bad:oops :

Did not understand what you mean.



 Privacy Policy  Copyright © 1999-2000 LSLNET.COM. All rights reserved. Blue Forest website owners. E-mail : Webmaster@lslnet.com