diff options
Diffstat (limited to 'apps/misc.c')
-rw-r--r-- | apps/misc.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/apps/misc.c b/apps/misc.c index f847023c31..b6eaafb599 100644 --- a/apps/misc.c +++ b/apps/misc.c | |||
@@ -28,9 +28,12 @@ | |||
28 | #include "misc.h" | 28 | #include "misc.h" |
29 | #include "system.h" | 29 | #include "system.h" |
30 | #include "lcd.h" | 30 | #include "lcd.h" |
31 | #ifdef HAVE_DIRCACHE | ||
32 | #include "dircache.h" | ||
33 | #endif | ||
31 | #include "file.h" | 34 | #include "file.h" |
32 | #ifndef __PCTOOL__ | 35 | #ifndef __PCTOOL__ |
33 | #include "filefuncs.h" | 36 | #include "pathfuncs.h" |
34 | #include "lang.h" | 37 | #include "lang.h" |
35 | #include "dir.h" | 38 | #include "dir.h" |
36 | #ifdef HAVE_REMOTE_LCD | 39 | #ifdef HAVE_REMOTE_LCD |
@@ -744,8 +747,7 @@ int show_logo( void ) | |||
744 | */ | 747 | */ |
745 | void check_bootfile(bool do_rolo) | 748 | void check_bootfile(bool do_rolo) |
746 | { | 749 | { |
747 | static unsigned short wrtdate = 0; | 750 | static time_t mtime = 0; |
748 | static unsigned short wrttime = 0; | ||
749 | DIR* dir = NULL; | 751 | DIR* dir = NULL; |
750 | struct dirent* entry = NULL; | 752 | struct dirent* entry = NULL; |
751 | 753 | ||
@@ -761,10 +763,9 @@ void check_bootfile(bool do_rolo) | |||
761 | { | 763 | { |
762 | struct dirinfo info = dir_get_info(dir, entry); | 764 | struct dirinfo info = dir_get_info(dir, entry); |
763 | /* found the bootfile */ | 765 | /* found the bootfile */ |
764 | if(wrtdate && do_rolo) | 766 | if(mtime && do_rolo) |
765 | { | 767 | { |
766 | if((info.wrtdate != wrtdate) || | 768 | if(info.mtime != mtime) |
767 | (info.wrttime != wrttime)) | ||
768 | { | 769 | { |
769 | static const char *lines[] = { ID2P(LANG_BOOT_CHANGED), | 770 | static const char *lines[] = { ID2P(LANG_BOOT_CHANGED), |
770 | ID2P(LANG_REBOOT_NOW) }; | 771 | ID2P(LANG_REBOOT_NOW) }; |
@@ -777,8 +778,7 @@ void check_bootfile(bool do_rolo) | |||
777 | } | 778 | } |
778 | } | 779 | } |
779 | } | 780 | } |
780 | wrtdate = info.wrtdate; | 781 | mtime = info.mtime; |
781 | wrttime = info.wrttime; | ||
782 | } | 782 | } |
783 | } | 783 | } |
784 | closedir(dir); | 784 | closedir(dir); |