Capabilities are unsigned
authorSimon Wilkinson <sxw@inf.ed.ac.uk>
Mon, 13 Jul 2009 17:24:42 +0000 (18:24 +0100)
committerDerrick Brashear <shadow@dementia.org>
Mon, 13 Jul 2009 17:57:28 +0000 (11:57 -0600)
Capabilities are defined in the .xg file as being an array of unsigned
ints. Implement them as such.

Reviewed-on: http://gerrit.openafs.org/72
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
Verified-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>

src/afs/afs_callback.c

index fd87bbf..87f3ec7 100644 (file)
@@ -1632,7 +1632,7 @@ SRXAFSCB_TellMeAboutYourself(struct rx_call *a_call,
 {
     int i;
     int code = 0;
-    afs_int32 *dataBuffP;
+    afs_uint32 *dataBuffP;
     afs_int32 dataBytes;
 
     RX_AFS_GLOCK();
@@ -1654,10 +1654,10 @@ SRXAFSCB_TellMeAboutYourself(struct rx_call *a_call,
 
     RX_AFS_GUNLOCK();
 
-    dataBytes = 1 * sizeof(afs_int32);
-    dataBuffP = (afs_int32 *) afs_osi_Alloc(dataBytes);
+    dataBytes = 1 * sizeof(afs_uint32);
+    dataBuffP = (afs_uint32 *) afs_osi_Alloc(dataBytes);
     dataBuffP[0] = CLIENT_CAPABILITY_ERRORTRANS;
-    capabilities->Capabilities_len = dataBytes / sizeof(afs_int32);
+    capabilities->Capabilities_len = dataBytes / sizeof(afs_uint32);
     capabilities->Capabilities_val = dataBuffP;
 
     return code;