9
0
Fork 0
barebox/commands
Uwe Kleine-König b78e5fe9f3 commands/crc: assert newline after output with big offsets
This fixes

	barebox@Very long board name:/ crc32 -f /dev/mem 0x83f00000+0xfff
	CRC32 for /dev/mem 0x83fff000 ... 0x83fffffe ==> 0xa080584bbarebox@Very long board name:/

The problem here was that the return value of
lseek(fd, 0x83f00000, SEEK_SET) (which is 0x83f00000) was casted to an
int (which is -2081423360), returned to do_crc and interpreted as
error there without yielding another error message.

This also makes

	crc32 -f /dev/mem 0xffffffff+0x1

die on a NULL pointer exception instead of reporting:

	lseek: No error

:-)

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-07-17 20:41:17 +02:00
..
Kconfig Merge branch 'for-next/poweroff' 2012-07-02 11:04:44 +02:00
Makefile Merge branch 'for-next/poweroff' 2012-07-02 11:04:44 +02:00
automount.c automount: optionally make directory 2012-04-15 16:50:54 +02:00
basename.c Add basename command 2012-06-30 16:53:59 +02:00
bmp.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
bootm.c resource: store 'end' instead of 'size' in struct resource 2012-07-01 08:18:53 +02:00
cat.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
cd.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
clear.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
cp.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
crc.c commands/crc: assert newline after output with big offsets 2012-07-17 20:41:17 +02:00
dfu.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
digest.c make parse_area_spec arguments loff_t 2012-06-30 16:53:24 +02:00
dirname.c Add dirname command 2012-06-30 16:53:59 +02:00
echo.c echo: Fix help 2012-05-14 08:35:19 +02:00
edit.c edit: Add a status line 2012-05-16 08:51:05 +02:00
exec.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
export.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
false.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
flash.c make parse_area_spec arguments loff_t 2012-06-30 16:53:24 +02:00
global.c add 'global' command 2012-05-14 08:57:01 +02:00
go.c common: fix typo cammand_var_complete 2012-06-30 12:47:04 +02:00
gpio.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
help.c complete: add help complete support 2012-04-30 20:37:39 +08:00
i2c.c Merge branch 'master' into next 2012-05-16 20:23:44 +02:00
insmod.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
iomem.c resource: store 'end' instead of 'size' in struct resource 2012-07-01 08:18:53 +02:00
led.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
linux16.c x86 linux16 command: Add missing include 2012-06-25 14:38:30 +02:00
linux_exec.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
loadb.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
loadenv.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
loads.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
login.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
ls.c make st_size in struct stat 64 bit 2012-06-30 16:53:24 +02:00
lsmod.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
magicvar.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
mem.c mem md: bail out without arguments 2012-07-05 20:49:02 +02:00
meminfo.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
memtest.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
menu.c menu: fix non command management support 2012-04-23 19:51:06 +08:00
mkdir.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
mount.c fs: drop struct mtab_entry 2012-03-17 18:16:03 +01:00
msleep.c commands: add msleep command 2012-06-30 12:47:04 +02:00
nand.c mtd: fix bad block ioctls 2012-07-10 19:07:33 +02:00
nandtest.c mtd: fix bad block ioctls 2012-07-10 19:07:33 +02:00
net.c remove dead rarpboot command 2012-06-30 12:47:04 +02:00
oftree.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
partition.c Removed duplicate definition for DEVFS_PARTITION_xxx 2012-05-13 21:58:19 +02:00
passwd.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
poweroff.c add 'poweroff' command 2012-06-30 12:47:25 +02:00
printenv.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
pwd.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
readline.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
reginfo.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
reset.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
rm.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
rmdir.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
saveenv.c Make errno a positive value 2012-05-14 08:35:54 +02:00
setenv.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
sleep.c common: fix typo cammand_var_complete 2012-06-30 12:47:04 +02:00
stddev.c fs: fix standard zero, full devices 2012-07-04 08:38:22 +02:00
test.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
time.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
timeout.c timeout: allow to set a variable with the key pressed 2012-05-14 08:37:39 +02:00
trigger.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
true.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
ubi.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
uimage.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
umount.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
uncompress.c commands: uncompress: fix description 2012-06-30 22:10:21 +02:00
usb.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
usbserial.c commands: remove struct command pointer from commands 2012-02-27 20:28:07 +01:00
version.c complete: add empty complete support 2012-04-30 20:37:40 +08:00
wd.c Add a simple watchdog framework 2012-06-29 15:16:34 +02:00
xyzModem.c xyzModem.c: fix 'dummy' is used uninitialized in this function warning 2010-12-21 10:23:41 +01:00