about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorJoe DF <joedf@live.ca>2019-10-15 10:24:07 -0400
committerGitHub <noreply@github.com>2019-10-15 10:24:07 -0400
commitcefae560bf0fb6fe7aef17098bfae1bf17d3cd92 (patch)
tree52df10e7901257a981222c4450b3daa815ca14e4
parenta8925f86c953d090b6bf8fb31f8b69a24c77fa7a (diff)
downloadbase64-cefae560bf0fb6fe7aef17098bfae1bf17d3cd92.tar.gz
Fix indentation, fix code style
-rw-r--r--base64.c51
1 files changed, 27 insertions, 24 deletions
diff --git a/base64.c b/base64.c
index 3b97eaa..a34c946 100644
--- a/base64.c
+++ b/base64.c
@@ -112,18 +112,20 @@ unsigned int b64_decode(const unsigned char* in, unsigned int in_len, unsigned i
 }
 
 unsigned int b64_encodef(char *InFile, char *OutFile) {
-	  FILE *pInFile = fopen(InFile,"rb");
-    FILE *pOutFile = fopen(OutFile,"wb");
-    unsigned int i=0;
-    unsigned int j=0;
-    unsigned int c=0;
-    unsigned int s[4];
-    if ((pInFile==NULL) || (pOutFile==NULL) )
-    {
-        if (pInFile!=NULL){fclose(pInFile);}
-        if (pOutFile!=NULL){fclose(pOutFile);}
-        return 0;
-    }
+
+	FILE *pInFile = fopen(InFile,"rb");
+	FILE *pOutFile = fopen(OutFile,"wb");
+	
+	unsigned int i=0;
+	unsigned int j=0;
+	unsigned int c=0;
+	unsigned int s[4];
+	
+	if ((pInFile==NULL) || (pOutFile==NULL) ) {
+		if (pInFile!=NULL){fclose(pInFile);}
+		if (pOutFile!=NULL){fclose(pOutFile);}
+		return 0;
+	}
 	
 	while(c!=EOF) {
 		c=fgetc(pInFile);
@@ -160,18 +162,19 @@ unsigned int b64_encodef(char *InFile, char *OutFile) {
 
 unsigned int b64_decodef(char *InFile, char *OutFile) {
 
-	  FILE *pInFile = fopen(InFile,"rb");
-    FILE *pOutFile = fopen(OutFile,"wb");
-    unsigned int c=0;
-    unsigned int j=0;
-    unsigned int k=0;
-    unsigned int s[4];
-    if ((pInFile==NULL) || (pOutFile==NULL) )
-    {
-        if (pInFile!=NULL){fclose(pInFile);}
-        if (pOutFile!=NULL){fclose(pOutFile);}
-        return 0;
-    }
+	FILE *pInFile = fopen(InFile,"rb");
+	FILE *pOutFile = fopen(OutFile,"wb");
+	
+	unsigned int c=0;
+	unsigned int j=0;
+	unsigned int k=0;
+	unsigned int s[4];
+	
+	if ((pInFile==NULL) || (pOutFile==NULL) ) {
+		if (pInFile!=NULL){fclose(pInFile);}
+		if (pOutFile!=NULL){fclose(pOutFile);}
+		return 0;
+	}
 	
 	while(c!=EOF) {
 		c=fgetc(pInFile);