diff options
author | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2012-07-01 12:29:47 +0200 |
---|---|---|
committer | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2012-07-01 12:34:59 +0200 |
commit | bf1c491c2b510648a3c1efc2c381e30635248d18 (patch) | |
tree | 039f50a8c5eaae0270e5ae295de4ee23a9ded9ed /rbutil/rbutilqt/base/bootloaderinstallipod.cpp | |
parent | d8f5a00fc1cd8beff431bd236377b3fccece29fd (diff) | |
download | rockbox-bf1c491c2b510648a3c1efc2c381e30635248d18.tar.gz rockbox-bf1c491c2b510648a3c1efc2c381e30635248d18.zip |
Move check for existing bootloader to ipodpatcher.
Bootloader handling is different on nano2g compared to the other supported Ipod
models. Since ipodpatcher handles this internally make ipodpatcher also provide
a way to check this when using from Rockbox Utility to avoid duplicating the
(already existing) checks in the latter.
Fixes wrong "bootloader already installed" message on nano2g.
Change-Id: Ibc658d775fbac7cf9a7e329d445fe97828a455d8
Diffstat (limited to 'rbutil/rbutilqt/base/bootloaderinstallipod.cpp')
-rw-r--r-- | rbutil/rbutilqt/base/bootloaderinstallipod.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/rbutil/rbutilqt/base/bootloaderinstallipod.cpp b/rbutil/rbutilqt/base/bootloaderinstallipod.cpp index cb69faa35b..249da13735 100644 --- a/rbutil/rbutilqt/base/bootloaderinstallipod.cpp +++ b/rbutil/rbutilqt/base/bootloaderinstallipod.cpp | |||
@@ -166,7 +166,7 @@ bool BootloaderInstallIpod::uninstall(void) | |||
166 | return false; | 166 | return false; |
167 | } | 167 | } |
168 | 168 | ||
169 | if (ipod.ipod_directory[0].entryOffset == 0) { | 169 | if (ipod_has_bootloader(&ipod) == 0) { |
170 | emit logItem(tr("No bootloader detected."), LOGERROR); | 170 | emit logItem(tr("No bootloader detected."), LOGERROR); |
171 | emit done(true); | 171 | emit done(true); |
172 | return false; | 172 | return false; |
@@ -199,8 +199,8 @@ BootloaderInstallBase::BootloaderType BootloaderInstallIpod::installed(void) | |||
199 | } | 199 | } |
200 | else { | 200 | else { |
201 | read_directory(&ipod); | 201 | read_directory(&ipod); |
202 | if(ipod.ipod_directory[0].entryOffset == 0 || ipod.macpod) { | 202 | getmodel(&ipod,(ipod.ipod_directory[ipod.ososimage].vers>>8)); |
203 | qDebug() << "[BootloaderInstallIpod] installed: BootloaderOther"; | 203 | if(!ipod_has_bootloader(&ipod)) { |
204 | result = BootloaderOther; | 204 | result = BootloaderOther; |
205 | } | 205 | } |
206 | else { | 206 | else { |