to avoid collisions with negative return values of bconfig()
meaning "not supported".
/* Configuring stream parameters */
enum bconfig_type {
- BCONFIG_IS_TEMP_FILE, /* 0=normal file, 1=temporary file, -1=shared fd */
+ BCONFIG_IS_TEMP_FILE, /* 0=normal file, 1=temporary file, 2=shared fd */
BCONFIG_KEEP_BACK_BUF, /* Optimize for bi-directional access */
};
bfdopen_shared(int fd, uns buflen)
{
struct fastbuf *f = bfdopen(fd, buflen);
- bconfig(f, BCONFIG_IS_TEMP_FILE, -1);
+ bconfig(f, BCONFIG_IS_TEMP_FILE, 2);
return f;
}