Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs

Pull btrfs fix from Chris Mason:
"I had this in my 3.16 merge window queue, but it is small and obvious
enough for 3.15. I cherry-picked and retested against current rc8"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
Btrfs: send, fix corrupted path strings for long paths

Changed files
+5 -2
fs
btrfs
+5 -2
fs/btrfs/send.c
··· 360 360 /* 361 361 * First time the inline_buf does not suffice 362 362 */ 363 - if (p->buf == p->inline_buf) 363 + if (p->buf == p->inline_buf) { 364 364 tmp_buf = kmalloc(len, GFP_NOFS); 365 - else 365 + if (tmp_buf) 366 + memcpy(tmp_buf, p->buf, old_buf_len); 367 + } else { 366 368 tmp_buf = krealloc(p->buf, len, GFP_NOFS); 369 + } 367 370 if (!tmp_buf) 368 371 return -ENOMEM; 369 372 p->buf = tmp_buf;