Back to index

glibc  2.9
Defines | Functions
getw.c File Reference
#include <stdio.h>
#include <libio/iolibio.h>

Go to the source code of this file.

Defines

#define fread(p, m, n, s)   INTUSE(_IO_fread) (p, m, n, s)

Functions

int getw (FILE *stream)

Define Documentation

#define fread (   p,
  m,
  n,
  s 
)    INTUSE(_IO_fread) (p, m, n, s)

Definition at line 22 of file getw.c.


Function Documentation

int getw ( FILE stream)

Definition at line 26 of file getw.c.

{
  int w;

  /* Is there a better way?  */
  if (fread ((void *) &w, sizeof (w), 1, stream) != 1)
    return EOF;
  return w;
}