made 'else' prettier
This commit is contained in:
parent
fafb8e8870
commit
7d36275b2a
@ -65,7 +65,8 @@ outputFlags encryptText(char *text, char *keyNew, inputFlags flags)
|
|||||||
if (numberBuffer > 26)
|
if (numberBuffer > 26)
|
||||||
{
|
{
|
||||||
numberBuffer += 70;
|
numberBuffer += 70;
|
||||||
} else
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
numberBuffer += 64;
|
numberBuffer += 64;
|
||||||
}
|
}
|
||||||
@ -104,7 +105,8 @@ outputFlags encryptText(char *text, char *keyNew, inputFlags flags)
|
|||||||
if (i != 0)
|
if (i != 0)
|
||||||
{
|
{
|
||||||
textBuffer = realloc(textBuffer, numberBuffer);
|
textBuffer = realloc(textBuffer, numberBuffer);
|
||||||
} else
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
textBuffer = malloc(numberBuffer);
|
textBuffer = malloc(numberBuffer);
|
||||||
}
|
}
|
||||||
|
@ -157,10 +157,12 @@ void generateTextKeyChain(char *key, int *textKeyChain, int textKeyChainSize)
|
|||||||
if ((numberBuffer + 1) % 3 == 0)
|
if ((numberBuffer + 1) % 3 == 0)
|
||||||
{
|
{
|
||||||
textKeyChain[i] = key[numberBuffer] * key[numberBuffer2];
|
textKeyChain[i] = key[numberBuffer] * key[numberBuffer2];
|
||||||
} else if ((numberBuffer + 1) % 2 == 0)
|
}
|
||||||
|
else if ((numberBuffer + 1) % 2 == 0)
|
||||||
{
|
{
|
||||||
textKeyChain[i] = key[numberBuffer] - key[numberBuffer2];
|
textKeyChain[i] = key[numberBuffer] - key[numberBuffer2];
|
||||||
} else
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
textKeyChain[i] = key[numberBuffer] + key[numberBuffer2];
|
textKeyChain[i] = key[numberBuffer] + key[numberBuffer2];
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user