Accesses long numeric data in a machine-independent fashion.
Object File Access Routine Library (libld.a)
long sgetl (Buffer) char *Buffer;
void sputl (Value, Buffer) long Value; char *Buffer;
The sgetl subroutine retrieves four bytes from memory starting at the location pointed to by the Buffer parameter. It then returns the bytes as a long Value with the byte ordering of the host machine.
The sputl subroutine stores the four bytes of the Value parameter into memory starting at the location pointed to by the Buffer parameter. The order of the bytes is the same across all machines.
Using the sputl and sgetl subroutines together provides a machine-independent way of storing long numeric data in an ASCII file. For example, the numeric data stored in the portable archive file format can be accessed with the sputl and sgetl subroutines.
Value | Specifies a 4-byte value to store into memory. |
Buffer | Points to a location in memory. |
These subroutines are part of Base Operating System (BOS) Runtime.
The ar file format, a.out file format.
Subroutines Overview in AIX Version 4.3 General Programming Concepts: Writing and Debugging Programs.