| iMatix home page
| << | < | > | >>
SFL Logo SFL
Version 2.11

 

file_write

#include "sflfile.h"
char *
file_write (
    FILE *stream,
    const char *string)

Synopsis

Writes a line of text to the specified output stream. If the variable file_crlf is TRUE, adds a carriage-return to the line being written to the output stream. This variable is supplied so that you can either ignore crlf issues (do nothing), or handle them explicitly (play with file_crlf). Returns the string written, or NULL if no data could be written to the file.

Source Code - (sflfile.c)

{
    ASSERT (stream);
    ASSERT (string);

    fputs (string, stream);
    if (file_crlf)
        fputc ('\r', stream);

    if (fputc ('\n', stream) == EOF)
        return (NULL);
    else
        return ((char *) string);
}

| << | < | > | >> iMatix Copyright © 1996-2000 iMatix Corporation