diff --git a/upnp/inc/upnp.h b/upnp/inc/upnp.h index 933d656..81d9b4b 100644 --- a/upnp/inc/upnp.h +++ b/upnp/inc/upnp.h @@ -36,6 +36,14 @@ //@{ +#if defined MYLIB_LARGEFILE_SENSITIVE && _FILE_OFFSET_BITS+0 != 64 + #if defined __GNUC__ + #warning libupnp requires largefile mode - use AC_SYS_LARGEFILE + #else + # error libupnp requires largefile mode - use AC_SYS_LARGEFILE + #endif +#endif + #include #ifdef __FreeBSD__ #include @@ -875,7 +883,7 @@ struct File_Info /** The length of the file. A length less than 0 indicates the size * is unknown, and data will be sent until 0 bytes are returned from * a read call. */ - int file_length; + off_t file_length; /** The time at which the contents of the file was modified; * The time system is always local (not GMT). */ @@ -969,7 +977,7 @@ struct UpnpVirtualDirCallbacks int (*seek) ( IN UpnpWebFileHandle fileHnd, /** The handle of the file to move the file pointer. */ - IN long offset, /** The number of bytes to move in the + IN off_t offset, /** The number of bytes to move in the file. Positive values move foward and negative values move backward. Note that this must be positive if the @@ -2707,4 +2715,3 @@ EXPORT_SPEC void UpnpFree( //@} The API #endif -