diff --git a/[refs] b/[refs] index f4090b70b8b4..06415d7504a3 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a1b08e75dff3dc18a88444803753e667bb1d126e +refs/heads/master: 8379e7c46cc48f51197dd663fc6676f47f2a1e71 diff --git a/trunk/fs/ocfs2/aops.c b/trunk/fs/ocfs2/aops.c index b401654011a2..8a1e61545f41 100644 --- a/trunk/fs/ocfs2/aops.c +++ b/trunk/fs/ocfs2/aops.c @@ -1747,8 +1747,8 @@ int ocfs2_write_begin_nolock(struct address_space *mapping, * we know zeros will only be needed in the first and/or last cluster. */ if (clusters_to_alloc || extents_to_split || - wc->w_desc[0].c_needs_zero || - wc->w_desc[wc->w_clen - 1].c_needs_zero) + (wc->w_clen && (wc->w_desc[0].c_needs_zero || + wc->w_desc[wc->w_clen - 1].c_needs_zero))) cluster_of_pages = 1; else cluster_of_pages = 0;