summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/delta.h
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-04-16 01:40:32 +0200
committerDan McGee <dan@archlinux.org>2011-04-16 01:40:32 +0200
commit202ade1398ca57070e56de24c3639f3048ecd784 (patch)
tree80dd701c713014ccd824ee8860daf3a5df925e60 /lib/libalpm/delta.h
parent4ffda3f05b034b55eb5159e0268a34c14b46e686 (diff)
downloadpacman-202ade1398ca57070e56de24c3639f3048ecd784.tar.gz
pacman-202ade1398ca57070e56de24c3639f3048ecd784.tar.xz
Include "config.h" in header files using off_t
This makes it absolutely dead easy to ensure off_t has the same length in all compilation units. I just spent 2.5 hours bashing my head on an issue related to this so damn it I'm fixing it for good. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/delta.h')
-rw-r--r--lib/libalpm/delta.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/libalpm/delta.h b/lib/libalpm/delta.h
index d7a81c47..bd196bab 100644
--- a/lib/libalpm/delta.h
+++ b/lib/libalpm/delta.h
@@ -20,6 +20,8 @@
#ifndef _ALPM_DELTA_H
#define _ALPM_DELTA_H
+#include "config.h" /* ensure off_t is correct length */
+
#include <sys/types.h> /* off_t */
#include "alpm.h"
@@ -29,12 +31,12 @@ struct __pmdelta_t {
char *delta;
/** md5sum of the delta file */
char *delta_md5;
- /** filesize of the delta file */
- off_t delta_size;
/** filename of the 'before' file */
char *from;
/** filename of the 'after' file */
char *to;
+ /** filesize of the delta file */
+ off_t delta_size;
/** download filesize of the delta file */
off_t download_size;
};