From 25feec0c9c6a2bd9fe4c20e3cfe55e47c3d4bfaf Mon Sep 17 00:00:00 2001
From: Gabor Juhos <juhosg@openwrt.org>
Date: Wed, 26 Jan 2011 20:35:37 +0000
Subject: package/base-files: add get_magic_long() to common upgrade script

Patch-by: Mark Mentovai <mark@moxienet.com>

SVN-Revision: 25117
---
 package/base-files/files/lib/upgrade/common.sh | 4 ++++
 1 file changed, 4 insertions(+)

(limited to 'package/base-files/files/lib/upgrade')

diff --git a/package/base-files/files/lib/upgrade/common.sh b/package/base-files/files/lib/upgrade/common.sh
index 970016e..bf9c40d 100644
--- a/package/base-files/files/lib/upgrade/common.sh
+++ b/package/base-files/files/lib/upgrade/common.sh
@@ -130,6 +130,10 @@ get_magic_word() {
 	get_image "$@" | dd bs=2 count=1 2>/dev/null | hexdump -v -n 2 -e '1/1 "%02x"'
 }
 
+get_magic_long() {
+	get_image "$@" | dd bs=4 count=1 2>/dev/null | hexdump -v -n 4 -e '1/1 "%02x"'
+}
+
 refresh_mtd_partitions() {
 	mtd refresh rootfs
 }
-- 
cgit v1.1