bf.c (132943) | bf.c (141858) |
---|---|
1/* 2 * Copyright (c) 1999-2002, 2004 Sendmail, Inc. and its suppliers. 3 * All rights reserved. 4 * 5 * By using this file, you agree to the terms and conditions set 6 * forth in the LICENSE file which can be found at the top level of 7 * the sendmail distribution. 8 * --- 4 unchanged lines hidden (view full) --- 13/* 14** This is in transition. Changed from the original bf_torek.c code 15** to use sm_io function calls directly rather than through stdio 16** translation layer. Will be made a built-in file type of libsm 17** next (once safeopen() linkable from libsm). 18*/ 19 20#include <sm/gen.h> | 1/* 2 * Copyright (c) 1999-2002, 2004 Sendmail, Inc. and its suppliers. 3 * All rights reserved. 4 * 5 * By using this file, you agree to the terms and conditions set 6 * forth in the LICENSE file which can be found at the top level of 7 * the sendmail distribution. 8 * --- 4 unchanged lines hidden (view full) --- 13/* 14** This is in transition. Changed from the original bf_torek.c code 15** to use sm_io function calls directly rather than through stdio 16** translation layer. Will be made a built-in file type of libsm 17** next (once safeopen() linkable from libsm). 18*/ 19 20#include <sm/gen.h> |
21SM_RCSID("@(#)$Id: bf.c,v 8.60 2004/04/14 18:12:49 ca Exp $") | 21SM_RCSID("@(#)$Id: bf.c,v 8.61 2004/08/03 23:59:02 ca Exp $") |
22 23#include <sys/types.h> 24#include <sys/stat.h> 25#include <sys/uio.h> 26#include <fcntl.h> 27#include <unistd.h> 28#include <stdlib.h> 29#include <string.h> 30#include <errno.h> 31#include "sendmail.h" 32#include "bf.h" 33 34#include <syslog.h> 35 36/* bf io functions */ 37static ssize_t sm_bfread __P((SM_FILE_T *, char *, size_t)); 38static ssize_t sm_bfwrite __P((SM_FILE_T *, const char *, size_t)); 39static off_t sm_bfseek __P((SM_FILE_T *, off_t, int)); 40static int sm_bfclose __P((SM_FILE_T *)); | 22 23#include <sys/types.h> 24#include <sys/stat.h> 25#include <sys/uio.h> 26#include <fcntl.h> 27#include <unistd.h> 28#include <stdlib.h> 29#include <string.h> 30#include <errno.h> 31#include "sendmail.h" 32#include "bf.h" 33 34#include <syslog.h> 35 36/* bf io functions */ 37static ssize_t sm_bfread __P((SM_FILE_T *, char *, size_t)); 38static ssize_t sm_bfwrite __P((SM_FILE_T *, const char *, size_t)); 39static off_t sm_bfseek __P((SM_FILE_T *, off_t, int)); 40static int sm_bfclose __P((SM_FILE_T *)); |
41static int sm_bfcommit __P((SM_FILE_T *)); 42static int sm_bftruncate __P((SM_FILE_T *)); |
|
41 42static int sm_bfopen __P((SM_FILE_T *, const void *, int, const void *)); 43static int sm_bfsetinfo __P((SM_FILE_T *, int , void *)); 44static int sm_bfgetinfo __P((SM_FILE_T *, int , void *)); 45 46/* 47** Data structure for storing information about each buffered file 48** (Originally in sendmail/bf_torek.h for the curious.) --- 811 unchanged lines hidden --- | 43 44static int sm_bfopen __P((SM_FILE_T *, const void *, int, const void *)); 45static int sm_bfsetinfo __P((SM_FILE_T *, int , void *)); 46static int sm_bfgetinfo __P((SM_FILE_T *, int , void *)); 47 48/* 49** Data structure for storing information about each buffered file 50** (Originally in sendmail/bf_torek.h for the curious.) --- 811 unchanged lines hidden --- |