mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-21 13:53:55 -07:00
Reduce some var scopes
This commit is contained in:
parent
ac6b0ec1ce
commit
732bc766f9
52 changed files with 318 additions and 409 deletions
|
@ -213,7 +213,6 @@ int detectPresco(uint8_t *dest, size_t *size) {
|
|||
// convert base 12 ID to sitecode & usercode & 8 bit other unknown code
|
||||
int getWiegandFromPresco(const char *Cmd, uint32_t *sitecode, uint32_t *usercode, uint32_t *fullcode, bool *Q5) {
|
||||
|
||||
uint8_t val = 0;
|
||||
bool hex = false, errors = false;
|
||||
uint8_t cmdp = 0;
|
||||
char id[11];
|
||||
|
@ -250,8 +249,8 @@ int getWiegandFromPresco(const char *Cmd, uint32_t *sitecode, uint32_t *usercode
|
|||
if (errors || cmdp == 0) return PM3_EINVARG;
|
||||
|
||||
if (!hex) {
|
||||
uint8_t val = 0;
|
||||
for (int index = 0; index < strlen(id); ++index) {
|
||||
|
||||
// Get value from number string.
|
||||
if (id[index] == '*')
|
||||
val = 10;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue