diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | src/dialogs/about.c | 7 |
2 files changed, 9 insertions, 3 deletions
@@ -1,5 +1,10 @@ 10-05-20 Cyrille Bagard <nocbos@gmail.com> + * src/dialogs/about.c: + Fix a bug: make sure all figures of revision are displayed. + +10-05-20 Cyrille Bagard <nocbos@gmail.com> + * src/arch/dalvik/instruction.c: * src/arch/dalvik/instruction.h: Add support for a few more Dalvik instructions. diff --git a/src/dialogs/about.c b/src/dialogs/about.c index 4f34a2c..e182f8f 100644 --- a/src/dialogs/about.c +++ b/src/dialogs/about.c @@ -59,6 +59,7 @@ GtkWidget *create_about_dialog(GtkWindow *parent) GtkWidget *image; /* Image chargée */ unsigned int revision; /* Numéro de révision */ unsigned int i; /* Boucle de parcours */ + unsigned int max; /* Nbre. de boucles à effectuer*/ unsigned int level; /* Unité la plus importante */ char buffer[16]; /* Nom d'image à forger */ GtkWidget *label; /* Etiquette inférieure */ @@ -98,11 +99,11 @@ GtkWidget *create_about_dialog(GtkWindow *parent) gtk_widget_set_size_request(image, 14, 18); revision = REVISION; + max = log(revision) / log(10); - for (i = 0; revision > 0; i++) + for (i = 0; i <= max; i++) { - level = log(revision) / log(10); - level = pow(10, level); + level = pow(10, max - i); snprintf(buffer, 16, "revision_%u.png", revision / level); |