Skip to content

Commit

Permalink
skip localization on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
iceman1001 committed Mar 14, 2024
1 parent 049c5f4 commit 7a98427
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions client/src/proxmark3.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@
#include "preferences.h"
#include "commonutil.h"

#ifdef _WIN32
#include <windows.h>
#else
#ifndef _WIN32
#include <locale.h>
#endif

Expand Down Expand Up @@ -108,17 +106,7 @@ static void showBanner_logo(LogoMode mode) {
}

static uint8_t detect_current_lang(void) {
#ifdef _WIN32
const char* lang[LOCALE_NAME_MAX_LENGTH];
if (GetUserDefaultLocaleName(lang, LOCALE_NAME_MAX_LENGTH) > 0) {
if (memcmp(lang, "fr", 2) == 0) {
return 2;
}
if (memcmp(lang, "es", 2) == 0) {
return 3;
}
}
#else
#ifndef _WIN32
const char* lang = setlocale(LC_ALL, "");
if (lang == NULL) {
return 1;
Expand Down

0 comments on commit 7a98427

Please sign in to comment.