ppd_file_new(3)

ppd_file_new3

Parse a ppd file and load it into the ppd_file_t structure.

Usage

#include <ppd.h>

ppd_file_t *ppd_file_new_from_filep(FILE* fp");"

ppd_file_t *ppd_file_new_from_fd(int fd");"

ppd_file_t *ppd_file_new(const char * filename");"

Overview

The ppd_file_new_from_filep function parses the specified PPD file.

Return values

Upon successful completion ppd_file_new_from_filep, ppd_file_new_from_fd , ppd_file_new return a ppd_file_t pointer. Otherwise, NULL is returned and errno is set.

ENODEV

the FILE pointer passed into ppd_file_new_from_filep or the file descriptor passed into ppd_file_new_from_fd is NULL.

EBADF

the file doesn't appear to be a PPD file.

ENOTTY

no idea what these errors are. Probably PPD parse errors.

Other errors can be returned in errno by a failure in fdopen or fopen.

Releases

Unchanged in 11 releases since Debian 3.0 (Woody).

  1. 3.0–12

From libppd-dev 2:0.10-9 in Debian 12 (Bookworm). Parsed by carta from the page's man source.