summaryrefslogtreecommitdiffstats
path: root/utils/rk27utils/rk27load/common.c
diff options
context:
space:
mode:
authorMarcin Bukat <marcin.bukat@gmail.com>2011-05-30 21:10:43 +0000
committerMarcin Bukat <marcin.bukat@gmail.com>2011-05-30 21:10:43 +0000
commit8f4202db285b2139cfee6269b838733d6d2a2306 (patch)
treea362bd367c35a03928b68485df0188e637e09ea3 /utils/rk27utils/rk27load/common.c
parent976a1699da373f01dabc9353b34aef261ebf740f (diff)
downloadrockbox-8f4202db285b2139cfee6269b838733d6d2a2306.tar.gz
rockbox-8f4202db285b2139cfee6269b838733d6d2a2306.tar.bz2
rockbox-8f4202db285b2139cfee6269b838733d6d2a2306.zip
Rockchip rk27xx utils
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29936 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'utils/rk27utils/rk27load/common.c')
-rw-r--r--utils/rk27utils/rk27load/common.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/utils/rk27utils/rk27load/common.c b/utils/rk27utils/rk27load/common.c
new file mode 100644
index 0000000000..b97cfbcd79
--- /dev/null
+++ b/utils/rk27utils/rk27load/common.c
@@ -0,0 +1,16 @@
+#include <stdint.h>
+#include <stdio.h>
+
+#include "common.h"
+
+uint32_t filesize(FILE * f)
+{
+ uint32_t filesize;
+
+ fseek(f, 0, SEEK_END);
+ filesize = ftell(f);
+ fseek(f, 0, SEEK_SET);
+
+ return filesize;
+}
+