GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
ffstdout(3) FreeBSD Library Functions Manual ffstdout(3)

#include <xtend/fast-file.h>
-lxtend

ffile_t *ffstdout()

None

ffstdout() is a simple wrapper function for connecting file descriptor 1 to an ffile_t object using ffdopen(3). This is useful for high-performance filter programs, where using the traditional FILE *stdout would cause a bottleneck.

The ffile_t system is simpler than and several times as fast as FILE on typical systems. It is intended for processing large files character-by-character, where low-level block I/O is not convenient, but FILE I/O causes a bottleneck.

Pointer to an ffile_t object if successful, NULL otherwise

ffile_t *stream;
// "-" as a filename argument traditionally indicates stdout
if ( strcmp(argv[arg], "-") == 0 )
    stream = ffstdout();
else
    stream = ffopen(argv[arg], O_WRONLY|O_CREAT|O_TRUNC);

ffopen(3), ffdopen(3)


Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.