diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/inode.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -840,7 +840,11 @@ unsigned int get_next_ino(void) } #endif - *p = ++res; + res++; + /* get_next_ino should not provide a 0 inode number */ + if (unlikely(!res)) + res++; + *p = res; put_cpu_var(last_ino); return res; } |