Version v0.3.41 - -m Suppress miniz library warnings, auto-select pad when only one available

This commit is contained in:
2025-12-27 11:49:29 -05:00
parent 6fe12e0c1c
commit e126e30889
4 changed files with 34 additions and 12 deletions

View File

@@ -23,7 +23,7 @@
#include <ctype.h>
// Version - Updated automatically by build.sh
#define OTP_VERSION "v0.3.39"
#define OTP_VERSION "v0.3.40"
// Constants
#define MAX_INPUT_SIZE 4096

View File

@@ -470,6 +470,13 @@ char* select_pad_interactive(const char* title, const char* prompt, pad_filter_t
return NULL;
}
// If only one pad available, auto-select it
if (pad_count == 1) {
printf("\n%s\n", title);
printf("Only one pad available - auto-selecting: %.16s...\n\n", pads[0].chksum);
return strdup(pads[0].chksum);
}
// Calculate minimal unique prefixes for each pad
char prefixes[100][65];
int prefix_lengths[100];