Back to index

glibc  2.9
Defines | Enumerations | Functions
stdio_ext.h File Reference
#include <stdio.h>

Go to the source code of this file.

Defines

#define FSETLOCKING_QUERY   FSETLOCKING_QUERY
#define FSETLOCKING_INTERNAL   FSETLOCKING_INTERNAL
#define FSETLOCKING_BYCALLER   FSETLOCKING_BYCALLER

Enumerations

enum  { FSETLOCKING_QUERY = 0, FSETLOCKING_QUERY = 0, FSETLOCKING_INTERNAL, FSETLOCKING_INTERNAL }

Functions

__BEGIN_DECLS size_t __fbufsize (FILE *__fp) __THROW
int __freading (FILE *__fp) __THROW
int __fwriting (FILE *__fp) __THROW
int __freadable (FILE *__fp) __THROW
int __fwritable (FILE *__fp) __THROW
int __flbf (FILE *__fp) __THROW
void __fpurge (FILE *__fp) __THROW
size_t __fpending (FILE *__fp) __THROW
void _flushlbf (void)
int __fsetlocking (FILE *__fp, int __type) __THROW

Define Documentation

Definition at line 39 of file stdio_ext.h.

Definition at line 36 of file stdio_ext.h.

Definition at line 32 of file stdio_ext.h.


Enumeration Type Documentation

anonymous enum
Enumerator:
FSETLOCKING_QUERY 
FSETLOCKING_QUERY 
FSETLOCKING_INTERNAL 
FSETLOCKING_INTERNAL 

Definition at line 28 of file stdio_ext.h.

{
  /* Query current state of the locking status.  */
  FSETLOCKING_QUERY = 0,
#define FSETLOCKING_QUERY   FSETLOCKING_QUERY
  /* The library protects all uses of the stream functions, except for
     uses of the *_unlocked functions, by calls equivalent to flockfile().  */
  FSETLOCKING_INTERNAL,
#define FSETLOCKING_INTERNAL       FSETLOCKING_INTERNAL
  /* The user will take care of locking.  */
  FSETLOCKING_BYCALLER
#define FSETLOCKING_BYCALLER       FSETLOCKING_BYCALLER
};

Function Documentation

Definition at line 22 of file __fbufsize.c.

{
  if (fp->_mode > 0)
    return fp->_wide_data->_IO_buf_end - fp->_wide_data->_IO_buf_base;
  else
    return fp->_IO_buf_end - fp->_IO_buf_base;
}

Here is the caller graph for this function:

int __flbf ( FILE __fp)

Definition at line 22 of file __flbf.c.

{
  return fp->_flags & _IO_LINE_BUF;
}

Here is the caller graph for this function:

size_t __fpending ( FILE __fp)

Definition at line 22 of file __fpending.c.

{
  if (fp->_mode > 0)
    return fp->_wide_data->_IO_write_ptr - fp->_wide_data->_IO_write_base;
  else
    return fp->_IO_write_ptr - fp->_IO_write_base;
}

Here is the caller graph for this function:

void __fpurge ( FILE __fp)

Definition at line 23 of file __fpurge.c.

{
  if (fp->_mode > 0)
    {
      /* Wide-char stream.  */
      if (_IO_in_backup (fp))
       INTUSE(_IO_free_wbackup_area) (fp);

      fp->_wide_data->_IO_read_end = fp->_wide_data->_IO_read_ptr;
      fp->_wide_data->_IO_write_ptr = fp->_wide_data->_IO_write_base;
    }
  else
    {
      /* Byte stream.  */
      if (_IO_in_backup (fp))
       INTUSE(_IO_free_backup_area) (fp);

      fp->_IO_read_end = fp->_IO_read_ptr;
      fp->_IO_write_ptr = fp->_IO_write_base;
    }
}

Here is the call graph for this function:

Here is the caller graph for this function:

int __freadable ( FILE __fp)

Definition at line 22 of file __freadable.c.

{
  return (fp->_flags & _IO_NO_READS) == 0;
}

Here is the caller graph for this function:

int __freading ( FILE __fp)

Definition at line 22 of file __freading.c.

{
  return ((fp->_flags & _IO_NO_WRITES)
         || ((fp->_flags & (_IO_CURRENTLY_PUTTING | _IO_NO_READS)) == 0
             && fp->_IO_read_base != NULL));
}

Here is the caller graph for this function:

int __fsetlocking ( FILE __fp,
int  __type 
)

Definition at line 24 of file __fsetlocking.c.

{
  int result = ((fp->_flags & _IO_USER_LOCK)
              ? FSETLOCKING_BYCALLER : FSETLOCKING_INTERNAL);

  if (type != FSETLOCKING_QUERY)
    {
      fp->_flags &= ~_IO_USER_LOCK;
      if (type == FSETLOCKING_BYCALLER)
        fp->_flags |= _IO_USER_LOCK;
    }

  return result;
}
int __fwritable ( FILE __fp)

Definition at line 22 of file __fwritable.c.

{
  return (fp->_flags & _IO_NO_WRITES) == 0;
}

Here is the caller graph for this function:

int __fwriting ( FILE __fp)

Definition at line 22 of file __fwriting.c.

{
  return fp->_flags & (_IO_NO_READS | _IO_CURRENTLY_PUTTING);
}

Here is the caller graph for this function:

void _flushlbf ( void  )