Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 86149
b: refs/heads/master
c: 90dc7d2
h: refs/heads/master
i:
  86147: 413def9
v: v3
  • Loading branch information
Harvey Harrison authored and Trond Myklebust committed Feb 20, 2008
1 parent 2ef62cd commit e2d0db1
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1227a74e2e0217a4ca155d1677bdbf5f69e32bed
refs/heads/master: 90dc7d2796edf94a9eaa838321a9734c8513e717
6 changes: 3 additions & 3 deletions trunk/fs/nfs/callback_xdr.c
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ static __be32 encode_attr_change(struct xdr_stream *xdr, const uint32_t *bitmap,
if (!(bitmap[0] & FATTR4_WORD0_CHANGE))
return 0;
p = xdr_reserve_space(xdr, 8);
if (unlikely(p == 0))
if (unlikely(!p))
return htonl(NFS4ERR_RESOURCE);
p = xdr_encode_hyper(p, change);
return 0;
Expand All @@ -267,7 +267,7 @@ static __be32 encode_attr_size(struct xdr_stream *xdr, const uint32_t *bitmap, u
if (!(bitmap[0] & FATTR4_WORD0_SIZE))
return 0;
p = xdr_reserve_space(xdr, 8);
if (unlikely(p == 0))
if (unlikely(!p))
return htonl(NFS4ERR_RESOURCE);
p = xdr_encode_hyper(p, size);
return 0;
Expand All @@ -278,7 +278,7 @@ static __be32 encode_attr_time(struct xdr_stream *xdr, const struct timespec *ti
__be32 *p;

p = xdr_reserve_space(xdr, 12);
if (unlikely(p == 0))
if (unlikely(!p))
return htonl(NFS4ERR_RESOURCE);
p = xdr_encode_hyper(p, time->tv_sec);
*p = htonl(time->tv_nsec);
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/nfs/delegation.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ static int nfs_delegation_claim_locks(struct nfs_open_context *ctx, struct nfs4_
struct file_lock *fl;
int status;

for (fl = inode->i_flock; fl != 0; fl = fl->fl_next) {
for (fl = inode->i_flock; fl != NULL; fl = fl->fl_next) {
if (!(fl->fl_flags & (FL_POSIX|FL_FLOCK)))
continue;
if (nfs_file_open_context(fl->fl_file) != ctx)
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/nfs/idmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ nfs_idmap_name(struct idmap *idmap, struct idmap_hashtable *h,
mutex_lock(&idmap->idmap_im_lock);

he = idmap_lookup_id(h, id);
if (he != 0) {
if (he) {
memcpy(name, he->ih_name, he->ih_namelen);
ret = he->ih_namelen;
goto out;
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/nfs/nfs4state.c
Original file line number Diff line number Diff line change
Expand Up @@ -785,7 +785,7 @@ static int nfs4_reclaim_locks(struct nfs4_state_recovery_ops *ops, struct nfs4_s
struct file_lock *fl;
int status = 0;

for (fl = inode->i_flock; fl != 0; fl = fl->fl_next) {
for (fl = inode->i_flock; fl != NULL; fl = fl->fl_next) {
if (!(fl->fl_flags & (FL_POSIX|FL_FLOCK)))
continue;
if (nfs_file_open_context(fl->fl_file)->state != state)
Expand Down

0 comments on commit e2d0db1

Please sign in to comment.