From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dan Carpenter Subject: re: overlay filesystem Date: Mon, 27 Oct 2014 16:54:49 +0300 Message-ID: <20141027135449.GA2465@mwanda> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-fsdevel@vger.kernel.org To: mszeredi@suse.cz Return-path: Received: from userp1040.oracle.com ([156.151.31.81]:16877 "EHLO userp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752655AbaJ0NzE (ORCPT ); Mon, 27 Oct 2014 09:55:04 -0400 Content-Disposition: inline Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Hello Miklos Szeredi, The patch e9be9d5e76e3: "overlay filesystem" from Oct 24, 2014, leads to the following static checker warning: fs/overlayfs/readdir.c:392 ovl_iterate() warn: this array is probably non-NULL. 'p->name' fs/overlayfs/readdir.c 387 while (od->cursor.l_node.next != &od->cache->entries) { 388 struct ovl_cache_entry *p; 389 390 p = list_entry(od->cursor.l_node.next, struct ovl_cache_entry, l_node); 391 /* Skip cursors */ 392 if (p->name) { ^^^^^^^ The "Skip cursors" comment suggests that some other check was intended? 393 if (!p->is_whiteout) { 394 if (!dir_emit(ctx, p->name, p->len, p->ino, p->type)) 395 break; 396 } 397 ctx->pos++; 398 } 399 list_move(&od->cursor.l_node, &p->l_node); 400 } There are a couple others as well. fs/overlayfs/readdir.c:254 ovl_dir_mark_whiteouts() warn: this array is probably non-NULL. 'p->name' fs/overlayfs/readdir.c:319 ovl_seek_cursor() warn: this array is probably non-NULL. 'p->name' regards, dan carpenter