Skip to content

Commit

Permalink
Fix errors reported by CI on undeclared variables
Browse files Browse the repository at this point in the history
- Try windows-friendly 32 unsigned integer type called unsigned long
  • Loading branch information
zz85 committed Mar 16, 2017
1 parent 7236ff3 commit daadbcc
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/keypress.c
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,11 @@ static void tapUniKey(char c)

void typeString(const char *str)
{
uint c, c1, c2, c3, n;
unsigned long c;
unsigned long c1;
unsigned long c2;
unsigned long c3;
unsigned long n;

while (*str != '\0') {
c = *str++;
Expand All @@ -254,8 +258,14 @@ void typeString(const char *str)
n = ((c & 0x07) << 18) | (c1 << 12) | (c2 << 6) | c3;
}

#if defined(IS_MACOSX)
toggleUnicodeKey(n, true);
toggleUnicodeKey(n, false);
#else
toggleUniKey(n, true);
toggleUniKey(n, false);
#endif

}
}

Expand Down

0 comments on commit daadbcc

Please sign in to comment.