diff options
-rw-r--r-- | fs/reiserfs/ibalance.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/reiserfs/ibalance.c b/fs/reiserfs/ibalance.c index b751eea..5db6f45 100644 --- a/fs/reiserfs/ibalance.c +++ b/fs/reiserfs/ibalance.c @@ -1153,8 +1153,9 @@ int balance_internal(struct tree_balance *tb, insert_ptr); } - memcpy(new_insert_key_addr, &new_insert_key, KEY_SIZE); insert_ptr[0] = new_insert_ptr; + if (new_insert_ptr) + memcpy(new_insert_key_addr, &new_insert_key, KEY_SIZE); return order; } |