~andreas-noteng/checkinstall/lucid

« back to all changes in this revision

Viewing changes to debian/patches/14fix-readlink.diff

  • Committer: Andreas Noteng
  • Date: 2010-03-06 05:34:10 UTC
  • Revision ID: andreas@noteng.no-20100306053410-yiclmtcs830cg5cc
init

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Index: checkinstall/installwatch-0.7.0beta5/installwatch.c
 
2
===================================================================
 
3
--- checkinstall.orig/installwatch-0.7.0beta5/installwatch.c    2008-06-25 19:56:49.000000000 -0400
 
4
+++ checkinstall/installwatch-0.7.0beta5/installwatch.c 2008-06-25 19:59:14.000000000 -0400
 
5
@@ -77,7 +77,7 @@
 
6
 static int (*true_open)(const char *, int, ...);
 
7
 static DIR *(*true_opendir)(const char *);
 
8
 static struct dirent *(*true_readdir)(DIR *dir);
 
9
-static int (*true_readlink)(const char*,char *,size_t);
 
10
+static ssize_t (*true_readlink)(const char*,char *,size_t);
 
11
 static char *(*true_realpath)(const char *,char *);
 
12
 static int (*true_rename)(const char *, const char *);
 
13
 static int (*true_rmdir)(const char *);
 
14
@@ -539,7 +539,7 @@
 
15
        struct utimbuf timbuf;
 
16
        size_t truesz;
 
17
        char linkpath[PATH_MAX+1];
 
18
-       size_t linksz;
 
19
+       ssize_t linksz;
 
20
 
 
21
 #if DEBUG
 
22
        debug(2,"copy_path(%s,%s)\n",truepath,translroot);
 
23
@@ -738,7 +738,7 @@
 
24
        char nwork[PATH_MAX+1];
 
25
        char nsuffix[PATH_MAX+1];
 
26
        char lnkpath[PATH_MAX+1];
 
27
-       size_t lnksz=0;
 
28
+       ssize_t lnksz=0;
 
29
        string_t *pthis=NULL;
 
30
        string_t *list1=NULL;
 
31
        string_t *list2=NULL;
 
32
@@ -1575,7 +1575,7 @@
 
33
        struct stat reslvinfo;
 
34
        instw_t iw;
 
35
        char wpath[PATH_MAX+1];
 
36
-       size_t wsz=0;
 
37
+       ssize_t wsz=0;
 
38
        char linkpath[PATH_MAX+1];
 
39
 
 
40
 
 
41
@@ -1671,7 +1671,7 @@
 
42
        struct stat sinfo;
 
43
        struct stat dinfo;
 
44
        int wfd;
 
45
-       size_t wsz;
 
46
+       ssize_t wsz;
 
47
        instw_t iw_entry;
 
48
        int status=0;
 
49
 
 
50
@@ -2691,8 +2691,8 @@
 
51
        return result;
 
52
 }
 
53
 
 
54
-int readlink(const char *path,char *buf,size_t bufsiz) {
 
55
-       int result;
 
56
+ssize_t readlink(const char *path,char *buf,size_t bufsiz) {
 
57
+       ssize_t result;
 
58
        instw_t instw;
 
59
        int status;
 
60