added checksum warning

This commit is contained in:
Václav Šmejkal 2024-11-19 22:30:18 +01:00
parent 7638881217
commit 5833502c7a
Signed by: ENGO150
GPG Key ID: 4A57E86482968843

View File

@ -21,7 +21,7 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
#include <string.h> #include <string.h>
#include <math.h> #include <math.h>
unsigned long why2_checksum_segment(char *input) unsigned long why2_checksum_segment(char *input) //I ABSOLUTELY DO NOT RECOMMEND USING THIS WITH LARGE KEYS!!!
{ {
unsigned long input_size = strlen(input); unsigned long input_size = strlen(input);
unsigned long segmented_input_size = ceil(input_size / (double) WHY2_CHECKSUM_SEGMENT_SIZE) * WHY2_CHECKSUM_SEGMENT_SIZE; //CALCULATE CLOSEST 4*n TO input unsigned long segmented_input_size = ceil(input_size / (double) WHY2_CHECKSUM_SEGMENT_SIZE) * WHY2_CHECKSUM_SEGMENT_SIZE; //CALCULATE CLOSEST 4*n TO input