summaryrefslogtreecommitdiffstats
path: root/rbutil/irivertools.cpp
diff options
context:
space:
mode:
authorDominik Wenger <domonoky@googlemail.com>2007-03-15 18:02:15 +0000
committerDominik Wenger <domonoky@googlemail.com>2007-03-15 18:02:15 +0000
commitc9cafd846fbc43fba9eb559cb86160a94f7f97a1 (patch)
tree80ca1998e0eee7176f7115026d29852bdd67a335 /rbutil/irivertools.cpp
parent410af8955f89ee5ff9498448bcc185988869bdb3 (diff)
downloadrockbox-c9cafd846fbc43fba9eb559cb86160a94f7f97a1.tar.gz
rockbox-c9cafd846fbc43fba9eb559cb86160a94f7f97a1.zip
more Unicode fixes for rutil, thanx to preglow. Also made Theme Preview window modeless
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12785 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'rbutil/irivertools.cpp')
-rwxr-xr-xrbutil/irivertools.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/rbutil/irivertools.cpp b/rbutil/irivertools.cpp
index a1c83ebd39..f993ce5e0a 100755
--- a/rbutil/irivertools.cpp
+++ b/rbutil/irivertools.cpp
@@ -170,11 +170,11 @@ bool mkboot(wxString infile, wxString outfile,wxString bootloader,int origin)
/* end mkboot.c excerpt */
-int intable(wxString md5, struct sumpairs *table, int len)
+int intable(char *md5, struct sumpairs *table, int len)
{
int i;
for (i = 0; i < len; i++) {
- if (md5.Cmp(table[i].unpatched) == 0) {
+ if (strncmp(md5, table[i].unpatched, 32) == 0) {
return i;
}
}
@@ -544,7 +544,7 @@ bool PatchFirmware(wxString firmware,wxString bootloader,int series, int table_e
{
wxString name1, name2, name3;
- wxString md5sum_str;
+ char md5sum_str[32];
int i;
struct sumpairs *sums;
int origin;
@@ -595,14 +595,14 @@ bool PatchFirmware(wxString firmware,wxString bootloader,int series, int table_e
return false;
}
/* now md5sum it */
- if (!FileMD5(name3, &md5sum_str)) {
+ if (!FileMD5(name3, md5sum_str)) {
ERR_DIALOG(wxT("Error in checksumming"),wxT("Checksumming Firmware"));
wxRemoveFile(name1);
wxRemoveFile(name2);
wxRemoveFile(name3);
return false;
}
- if (strncmp(sums[table_entry].patched, md5sum_str.c_str(), 32) == 0) {
+ if (strncmp(sums[table_entry].patched, md5sum_str, 32) == 0) {
/* delete temp files */
wxRemoveFile(name1);
wxRemoveFile(name2);