kayws426 / embox

Automatically exported from code.google.com/p/embox
0 stars 1 forks source link

mutex_lock double lock in bcache #640

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I fixed it in bcache.c in function:

static void free_more_memory(size_t size) 

line 72:
/*XXX */
if(bh->flags & BH_LOCKED) {
   continue;
}
but it's a quick & dirty hack

for more details you can contact me (Gaz)

Original issue reported on code.google.com by Gazukin....@gmail.com on 29 Aug 2013 at 7:09

GoogleCodeExporter commented 9 years ago
Hi! I don't understood the problem, but you can try to add forgotten unlock:
line 79-81:
                        if (!free_all && bh->blocksize != size) {
                                bcache_buffer_unlock(bh);
                                continue;
                        }

Original comment by alexkalmuk@gmail.com on 29 Aug 2013 at 5:06

GoogleCodeExporter commented 9 years ago

Original comment by alexkalmuk@gmail.com on 13 Mar 2015 at 10:57