if (end == 0) {
struct vattr va;
- if (pn->pn_va.va_size == start)
+ if (pn->pn_va.va_size == (u_quad_t) start)
return(OK);
if (global_pu->pu_ops.puffs_node_setattr == NULL)
char path[PATH_MAX];
PUFFS_MAKECRED(pcr, &global_kcred);
- copylen = fs_m_in.REQ_MEM_SIZE < UMAX_FILE_POS ?
- fs_m_in.REQ_MEM_SIZE : UMAX_FILE_POS;
+ copylen = (size_t) fs_m_in.REQ_MEM_SIZE < UMAX_FILE_POS ?
+ (size_t) fs_m_in.REQ_MEM_SIZE : UMAX_FILE_POS;
assert(copylen <= PATH_MAX);
return errno;
/* sloppy */
- if (va->va_atime.tv_sec != (unsigned)PUFFS_VNOVAL
- || va->va_mtime.tv_sec != (unsigned)PUFFS_VNOVAL) {
+ if (va->va_atime.tv_sec != PUFFS_VNOVAL
+ || va->va_mtime.tv_sec != PUFFS_VNOVAL) {
/* FIXME: nsec too */
tbuf.actime = va->va_atime.tv_sec;
tbuf.modtime = va->va_mtime.tv_sec;
/* FIXME: DIRENT_SIZE macro? For now do calculations here */
int namelen;
char* cp;
- int dirent_size;
+ size_t dirent_size;
entry = readdir(dp);
if (r != OK) return(r);
target[fs_m_in.REQ_MEM_SIZE] = '\0';
- if (strlen(target) != fs_m_in.REQ_MEM_SIZE) {
+ if (strlen(target) != (size_t) fs_m_in.REQ_MEM_SIZE) {
/* This can happen if the user provides a buffer
* with a \0 in it. This can cause a lot of trouble
* when the symlink is used later. We could just use
/*ARGSUSED*/
-static void
+__dead static void
puffs_defaulterror(struct puffs_usermount *pu, uint8_t type,
int error, const char *str, puffs_cookie_t cookie)
{
void
puffs_setstacksize(struct puffs_usermount *pu, size_t ss)
{
- long psize, minsize;
+ size_t minsize;
+ int psize;
int stackshift;
int bonus;
return(EINVAL);
puffs_vattr_null(&va);
- if ( (pos + bytes_left) > pn->pn_va.va_size)
+ if ((u_quad_t)(pos + bytes_left) > pn->pn_va.va_size)
va.va_size = bytes_left + pos;
va.va_ctime = va.va_mtime = clock_timespec();
va.va_atime = pn->pn_va.va_atime;
struct statvfs st;
struct super_block *sp;
int r, scale;
- uint64_t used;
+ u64_t used;
sp = get_super(fs_dev);