c8503f779656f0499f22fd6ae649e74a971b26fc
[nfs-utils.git] / debian / patches / 10-ccachedir-off-by-one.patch
1 Index: nfs-utils-1.0.11~git-20060105/utils/gssd/gssd.c
2 ===================================================================
3 --- nfs-utils-1.0.11~git-20060105.orig/utils/gssd/gssd.c
4 +++ nfs-utils-1.0.11~git-20060105/utils/gssd/gssd.c
5 @@ -122,7 +122,7 @@ main(int argc, char *argv[])
6                                 break;
7                         case 'd':
8                                 strncpy(ccachedir, optarg, sizeof(ccachedir));
9 -                               if (ccachedir[sizeof(ccachedir-1)] != '\0')
10 +                               if (ccachedir[sizeof(ccachedir)-1] != '\0')
11                                         errx(1, "ccachedir path name too long");
12                                 break;
13                         default: