lkml.org 
[lkml]   [2008]   [May]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: ext3_dx_add_entry: Directory index full!
From
Date
On Sun, 2008-05-18 at 17:36 +0200, Bernie Innocenti wrote:
>
>
> static inline unsigned dx_root_limit (struct inode *dir, unsigned
> infosize)
> {
> unsigned entry_space = dir->i_sb->s_blocksize -
> EXT3_DIR_REC_LEN(1) -
> EXT3_DIR_REC_LEN(2) - infosize;
> return 0? 20: entry_space / sizeof(struct dx_entry);
> }
>
> Am I reading the above code correctly? Why does it always return
> 20 no matter what?

It doesn't. "condition?A:B" will return A if the condition is _true_,
which it isn't.

--
dwmw2



\
 
 \ /
  Last update: 2008-05-18 17:43    [W:0.054 / U:2.076 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site