diff options
| author | Anser <rostgans@tutamail.com> | 2026-08-17 12:21:55 +0200 |
|---|---|---|
| committer | Anser <rostgans@tutamail.com> | 2026-08-17 12:21:55 +0200 |
| commit | 4ec1b7740fa70e4433c9a47ff6cf59cd113fdc18 (patch) | |
| tree | b5fd7cae31901a927a5e1fb4b737a4e234093285 /src/ascii.c | |
| parent | 85322effa3eae7b7f0f7550f976fd6f83c874a00 (diff) | |
changed MAX_LOGOS check to prevent out of bounce segfault
Diffstat (limited to 'src/ascii.c')
| -rw-r--r-- | src/ascii.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ascii.c b/src/ascii.c index b47b400..0a2dc67 100644 --- a/src/ascii.c +++ b/src/ascii.c @@ -34,7 +34,7 @@ static const struct ascii_mapping_t ascii_mappings[] = const char* get_ascii_name(const struct ascii_mapping_t *d_map, int art) { - if (art > MAX_LOGOS) { + if (art >= MAX_LOGOS) { fprintf(stderr, "get_ascii_path: index out of bounce\n"); fprintf(stderr, "Get default ascii art.\n"); art = 0; |
