proxmark3/client/src/guidummy.cpp
Rick Farina (Zero_Chaos) d522a46fca
fix lto-type-mismatch in guidummy.cpp
link time optimization requires all functions named the same to actually
operate the same.  I am pretty sure this fixes it without breaking
anything.
Fixes: https://github.com/RfidResearchGroup/proxmark3/issues/2058

src/proxgui.h:35:6: error: type of ‘ShowPictureWindow’ does not match original declaration [-Werror=lto-type-mismatch]
   35 | void ShowPictureWindow(uint8_t *data, int len);
      |      ^
src/guidummy.cpp:33:17: note: type mismatch in parameter 2
   33 | extern "C" void ShowPictureWindow(char *fn) {
      |                 ^
src/guidummy.cpp:33:17: note: type ‘void’ should match type ‘int’
src/guidummy.cpp:33:17: note: ‘ShowPictureWindow’ was previously declared here
2023-07-31 15:57:09 -04:00

55 lines
1.7 KiB
C++

//-----------------------------------------------------------------------------
// Copyright (C) Proxmark3 contributors. See AUTHORS.md for details.
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// See LICENSE.txt for the text of the license.
//-----------------------------------------------------------------------------
// GUI dummy file
//-----------------------------------------------------------------------------
#include <stdio.h>
extern "C" void ShowGraphWindow(void) {
static int warned = 0;
if (!warned) {
printf("No GUI in this build!\n");
warned = 1;
}
}
extern "C" void HideGraphWindow(void) {}
extern "C" void RepaintGraphWindow(void) {}
extern "C" void ShowPictureWindow(char *fn, int len) {
static int warned = 0;
if (!warned) {
printf("No GUI in this build!\n");
warned = 1;
}
}
extern "C" void ShowBase64PictureWindow(char *b64) {
static int warned = 0;
if (!warned) {
printf("No GUI in this build!\n");
warned = 1;
}
}
extern "C" void HidePictureWindow(void) {}
extern "C" void RepaintPictureWindow(void) {}
extern "C" void MainGraphics() {}
extern "C" void InitGraphics(int argc, char **argv) {}
extern "C" void ExitGraphics(void) {}