[U-Boot] [PATCH] UBIFS: Change ubifsload to not read beyond the requested size

2010-10-29 Thread Stefan Roese
Until now ubifsload pads the destination with 0 up to a multiple of UBIFS_BLOCK_SIZE (4KiB) while reading a file to memory. This patch changes this behaviour to only read to the requested length. This is either the file length or the length/size provided as parameter to the ubifsload command. Sign

Re: [U-Boot] [PATCH] UBIFS: Change ubifsload to not read beyond the requested size

2010-10-29 Thread Ben Gardiner
On Fri, Oct 29, 2010 at 5:04 AM, Stefan Roese wrote: > Until now ubifsload pads the destination with 0 up to a multiple of > UBIFS_BLOCK_SIZE (4KiB) while reading a file to memory. This patch > changes this behaviour to only read to the requested length. This > is either the file length or the len

Re: [U-Boot] [PATCH] UBIFS: Change ubifsload to not read beyond the requested size

2010-10-29 Thread Wolfgang Denk
Dear Stefan Roese, In message <1288343093-31276-1-git-send-email...@denx.de> you wrote: > Until now ubifsload pads the destination with 0 up to a multiple of > UBIFS_BLOCK_SIZE (4KiB) while reading a file to memory. This patch > changes this behaviour to only read to the requested length. This > i

Re: [U-Boot] [PATCH] UBIFS: Change ubifsload to not read beyond the requested size

2010-11-01 Thread Stefan Roese
Hi Wolfgang, On Friday 29 October 2010 22:54:04 Wolfgang Denk wrote: > > + buff = malloc(UBIFS_BLOCK_SIZE); > > + > > + /* Read block-siez into temp buffer */ > > + ret = read_block(inode, buff, block, dn); > > +

Re: [U-Boot] [PATCH] UBIFS: Change ubifsload to not read beyond the requested size

2010-11-01 Thread Stefan Roese
Hi Ben, On Friday 29 October 2010 16:01:18 Ben Gardiner wrote: > On Fri, Oct 29, 2010 at 5:04 AM, Stefan Roese wrote: > > Until now ubifsload pads the destination with 0 up to a multiple of > > UBIFS_BLOCK_SIZE (4KiB) while reading a file to memory. This patch > > changes this behaviour to only r