summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSeppia <seppia@seppio.fish>2018-07-06 01:41:20 +0200
committerSeppia <seppia@seppio.fish>2018-07-06 01:41:20 +0200
commitcd5d8fcfa37dd2321a54168c5784cada8da6035c (patch)
tree6604e31aa60b29f57ec902190021a9fd5e44ad78
parent6d532fd3993f2c86a39071636bf330135541f80f (diff)
downloadonetimebluh-cd5d8fcfa37dd2321a54168c5784cada8da6035c.tar.gz
onetimebluh-cd5d8fcfa37dd2321a54168c5784cada8da6035c.tar.bz2
onetimebluh-cd5d8fcfa37dd2321a54168c5784cada8da6035c.zip
Variable names
Adjusted variable names in readInput prototype.
-rw-r--r--src/libluh.c10
-rw-r--r--src/libluh.h2
2 files changed, 6 insertions, 6 deletions
diff --git a/src/libluh.c b/src/libluh.c
index b7412b4..2ef11ca 100644
--- a/src/libluh.c
+++ b/src/libluh.c
@@ -4,18 +4,18 @@
#include <string.h>
#include "libluh.h"
-char* readInput (FILE* stdinput, uint64_t size) {
+char* readInput (FILE* inputFile, uint64_t allocSize) {
int64_t character;
uint64_t length = 0;
char* input;
- input = malloc (sizeof (char) * size);
+ input = malloc (sizeof (char) * allocSize);
- while (EOF != (character = fgetc (stdinput))) {
+ while (EOF != (character = fgetc (inputFile))) {
input[length++] = character;
- if (length == size) {
- input = realloc (input, sizeof (char) * (size += 8));
+ if (length == allocSize) {
+ input = realloc (input, sizeof (char) * (allocSize += 8));
}
}
diff --git a/src/libluh.h b/src/libluh.h
index 2e44c01..77a8d52 100644
--- a/src/libluh.h
+++ b/src/libluh.h
@@ -12,7 +12,7 @@ typedef struct opts {
char* output;
} Opts;
-char* readInput (FILE* input, uint64_t size);
+char* readInput (FILE* inputFile, uint64_t allocSize);
char* cryptXor (char* inputStr, FILE* keyFile);
char* fcryptXor (FILE* inputFile, FILE* keyFile);
char* binDump (char* inputStr, char* binChars);