mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-22 10:30:13 +00:00
switched unsigned int to cfs_offset_t
This commit is contained in:
parent
e485c209b1
commit
6615e39e27
@ -30,7 +30,7 @@
|
||||
*
|
||||
* Author: Adam Dunkels <adam@sics.se>
|
||||
*
|
||||
* $Id: cfs-eeprom.c,v 1.9 2009/02/27 14:25:38 nvt-se Exp $
|
||||
* $Id: cfs-eeprom.c,v 1.10 2009/02/27 14:50:35 nvt-se Exp $
|
||||
*/
|
||||
|
||||
#include "cfs/cfs.h"
|
||||
@ -105,8 +105,8 @@ cfs_write(int f, const void *buf, unsigned int len)
|
||||
}
|
||||
}
|
||||
/*---------------------------------------------------------------------------*/
|
||||
unsigned int
|
||||
cfs_seek(int f, unsigned int o, int w)
|
||||
cfs_offset_t
|
||||
cfs_seek(int f, cfs_offset_t o, int w)
|
||||
{
|
||||
if(w == CFS_SEEK_SET && f == 1) {
|
||||
file.fileptr = o;
|
||||
|
@ -30,7 +30,7 @@
|
||||
*
|
||||
* Author: Adam Dunkels <adam@sics.se>
|
||||
*
|
||||
* $Id: cfs-posix.c,v 1.13 2009/02/27 14:25:38 nvt-se Exp $
|
||||
* $Id: cfs-posix.c,v 1.14 2009/02/27 14:50:35 nvt-se Exp $
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
@ -85,7 +85,7 @@ cfs_write(int f, const void *b, unsigned int l)
|
||||
}
|
||||
/*---------------------------------------------------------------------------*/
|
||||
cfs_offset_t
|
||||
cfs_seek(int f, unsigned int o, int w)
|
||||
cfs_seek(int f, cfs_offset_t o, int w)
|
||||
{
|
||||
if(w == CFS_SEEK_SET) {
|
||||
w = SEEK_SET;
|
||||
|
@ -54,28 +54,28 @@
|
||||
*
|
||||
* Author: Adam Dunkels <adam@sics.se>
|
||||
*
|
||||
* $Id: cfs.h,v 1.13 2009/02/27 14:25:38 nvt-se Exp $
|
||||
* $Id: cfs.h,v 1.14 2009/02/27 14:50:35 nvt-se Exp $
|
||||
*/
|
||||
#ifndef __CFS_H__
|
||||
#define __CFS_H__
|
||||
|
||||
#include "contiki.h"
|
||||
|
||||
#ifndef CFS_OFFSET_TYPE
|
||||
typedef unsigned cfs_offset_t;
|
||||
#else
|
||||
typedef CFS_OFFSET_TYPE cfs_offset_t;
|
||||
#endif
|
||||
|
||||
struct cfs_dir {
|
||||
char dummy_space[32];
|
||||
};
|
||||
|
||||
struct cfs_dirent {
|
||||
char name[32];
|
||||
unsigned int size;
|
||||
cfs_offset_t size;
|
||||
};
|
||||
|
||||
#ifndef CFS_OFFSET_TYPE
|
||||
typedef unsigned cfs_offset_t;
|
||||
#else
|
||||
typedef CFS_OFFSET_TYPE cfs_offset_t;
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Specify that cfs_open() should open a file for reading.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user