unixdev.net


Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (SunOS-4.1.3)
Page:
Section:
Apropos / Subsearch:
optional field

SPUTL(3V)                                                            SPUTL(3V)



NAME
       sputl,  sgetl - access long integer data in a machine-independent fash-
       ion

SYNOPSIS
       void sputl(value, buffer)
       long value;
       char *buffer;

       long sgetl(buffer)
       char *buffer;

DESCRIPTION
       sputl() takes the four bytes of the long integer values and places them
       in  memory  starting at the address pointed to by buffer.  The ordering
       of the bytes is the same across all machines.

       sgetl() retrieves the four bytes in  memory  starting  at  the  address
       pointed  to  by  buffer  and returns the long integer value in the byte
       ordering of the host machine.

       The combination of sputl() and sgetl() provides  a  machine-independent
       way  of storing long numeric data in a file in binary form without con-
       version to characters.



                                 16 June 1988                        SPUTL(3V)