/*
* Common RTC functions
+ *
+ * Licensed under GPLv2, see file LICENSE in this tarball for details.
*/
#include "libbb.h"
# define ADJTIME_PATH "/etc/adjtime"
#endif
-int rtc_adjtime_is_utc(void)
+int FAST_FUNC rtc_adjtime_is_utc(void)
{
int utc = 0;
- FILE *f = fopen(ADJTIME_PATH, "r");
+ FILE *f = fopen_for_read(ADJTIME_PATH);
if (f) {
RESERVE_CONFIG_BUFFER(buffer, 128);
return utc;
}
-int rtc_xopen(const char **default_rtc, int flags)
+int FAST_FUNC rtc_xopen(const char **default_rtc, int flags)
{
int rtc;
return xopen(*default_rtc, flags);
}
-time_t rtc_read_time(int fd, int utc)
+time_t FAST_FUNC rtc_read_time(int fd, int utc)
{
struct tm tm;
char *oldtz = 0;