Bill Garrison avatar Bill Garrison committed 626f7ce Merge

Merge xar-36.2 mods to default.

Comments (0)

Files changed (4)

xar.xcodeproj/project.pbxproj

 				ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)";
 				ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc";
 				COPY_PHASE_STRIP = NO;
-				CURRENT_PROJECT_VERSION = 36.1;
+				CURRENT_PROJECT_VERSION = 36.2;
 				STRIP_STYLE = debugging;
 				VERSIONING_SYSTEM = "apple-generic";
 			};
 			isa = XCBuildConfiguration;
 			buildSettings = {
 				COPY_PHASE_STRIP = YES;
-				CURRENT_PROJECT_VERSION = 36.1;
+				CURRENT_PROJECT_VERSION = 36.2;
 				EXECUTABLE_PREFIX = lib;
 				GCC_ENABLE_FIX_AND_CONTINUE = NO;
 				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
 			isa = XCBuildConfiguration;
 			buildSettings = {
 				COPY_PHASE_STRIP = YES;
-				CURRENT_PROJECT_VERSION = 36.1;
+				CURRENT_PROJECT_VERSION = 36.2;
 				GCC_ENABLE_FIX_AND_CONTINUE = NO;
 				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
 				GCC_MODEL_TUNING = G5;
 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '0', '1', '2',
 '3', '4', '5', '6', '7', '8', '9', '+', '/' };
 
-unsigned char* xar_to_base64(const unsigned char* input, int len)
+unsigned char* xar_to_base64(const unsigned char* input, size_t len)
 {
     unsigned char b6;
     /*UNUSED unsigned char tmp; */
     int i=0;
     unsigned char* output;
     int outsize = (((float)len)*4/3)+5;
+	
 
     output = malloc(outsize);
     if( !output )
 #define B64_INPUT_BLOCK_OFFSET	((inputIndex - 1 - ignorableCharacterCount) % 4)
 
 static unsigned int raw_base64_decode(
-  const unsigned char *input, unsigned char *output, int inLengthToDecode,
-  unsigned int *outputDecodedLength)
+  const unsigned char *input, unsigned char *output, size_t inLengthToDecode,
+  size_t *outputDecodedLength)
 {
     int currentBase64Value;
 	unsigned int inputIndex = 0;
-	unsigned int *decodedCharacterCount;
-	unsigned int dummyValue;
 	unsigned int ignorableCharacterCount = 0;
 	unsigned int i;
     unsigned char decodedBuffer[3];
 	unsigned char currentInputBlockPaddingCharacterCount = 0;
+	size_t *decodedCharacterCount;
+	size_t dummyValue;
 	
 	if (outputDecodedLength == NULL) {
 		// do this so that if caller passes in NULL for outputDecodedLength
     return B64_noError;
 }
 
-unsigned char* xar_from_base64(const unsigned char* input, int inputLength, unsigned int *outputLength)
+unsigned char* xar_from_base64(const unsigned char* input, size_t inputLength, size_t *outputLength)
 {
     int err;
     unsigned char *output;
 #ifndef _XAR_BASE64_H_
 #define _XAR_BASE64_H_
 
-unsigned char* xar_to_base64(const unsigned char* input, int len);
-unsigned char* xar_from_base64(const unsigned char* input, int inputLength, unsigned int *outputLength);
+unsigned char* xar_to_base64(const unsigned char* input, size_t len);
+unsigned char* xar_from_base64(const unsigned char* input, size_t inputLength, size_t *outputLength);
 
 #endif /* _XAR_BASE64_H_ */

xar/lib/signature.c

 	const xmlChar *value = NULL;
 	const xmlChar *name = NULL;
 	int type;
-	unsigned int outputLength;
+	size_t outputLength = 0;
 	
 	ret = malloc(sizeof(struct __xar_signature_t));
 	
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.