pad color output with zeros to be at least 6 letters long
This commit is contained in:
parent
0df4eebd91
commit
548abe4349
1 changed files with 1 additions and 1 deletions
2
fbflut.c
2
fbflut.c
|
@ -63,7 +63,7 @@ void *handle_connection(void *socket_desc) {
|
||||||
|
|
||||||
if (xpos >= 0 && ypos >= 0 && xpos < fb_width && ypos < fb_height) {
|
if (xpos >= 0 && ypos >= 0 && xpos < fb_width && ypos < fb_height) {
|
||||||
if (colorcode[0] == '\0') {
|
if (colorcode[0] == '\0') {
|
||||||
sprintf(message, "PX %i %i %X\n",xpos,ypos,fbdata[ypos*fb_length+xpos]);
|
sprintf(message, "PX %i %i %06X\n",xpos,ypos,fbdata[ypos*fb_length+xpos]);
|
||||||
write(sock, message, strlen(message));
|
write(sock, message, strlen(message));
|
||||||
continue;
|
continue;
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue