From: marshmellow42 Date: Tue, 16 Feb 2016 14:38:37 +0000 (-0500) Subject: use memcpy instead of re-assign pointer X-Git-Tag: v2.3.0~6^2 X-Git-Url: http://cvs.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/commitdiff_plain/38b3509542c4a5451a5701be0b073acbd7f79465 use memcpy instead of re-assign pointer --- diff --git a/client/cmddata.c b/client/cmddata.c index c43dfaf1..900cfc83 100644 --- a/client/cmddata.c +++ b/client/cmddata.c @@ -924,16 +924,16 @@ char *GetFSKType(uint8_t fchigh, uint8_t fclow, uint8_t invert) char *fskType = fType; if (fchigh==10 && fclow==8){ if (invert) //fsk2a - fskType = "FSK2a"; + memcpy(fskType, "FSK2a", 5); else //fsk2 - fskType = "FSK2"; + memcpy(fskType, "FSK2", 4); } else if (fchigh == 8 && fclow == 5) { if (invert) - fskType = "FSK1"; + memcpy(fskType, "FSK1", 4); else - fskType = "FSK1a"; + memcpy(fskType, "FSK1a", 5); } else { - fskType = "FSK??"; + memcpy(fskType, "FSK??", 5); } return fskType; }