| 149 | } |
| 150 | |
| 151 | static int |
| 152 | BufferGetchar(void) |
| 153 | { |
| 154 | int c; |
| 155 | |
| 156 | if (KbdBuffered > 0) { |
| 157 | c = KbdBuffer[0]; |
| 158 | KbdBuffered--; |
| 159 | /* Move the remaining characters */ |
| 160 | if (KbdBuffered < sizeof(KbdBuffer)) |
| 161 | memcpy(KbdBuffer, KbdBuffer + 1, KbdBuffered); |
| 162 | return c; |
| 163 | } |
| 164 | |
| 165 | return NO_CHAR; |
| 166 | } |
| 167 | |
| 168 | /* |
| 169 | * This should remind you remotely of DeadKeyConvert, but we are cheating |
no outgoing calls
no test coverage detected