diff --git a/photoboothled.c b/photoboothled.c index 24ca052..15e9a7e 100644 --- a/photoboothled.c +++ b/photoboothled.c @@ -79,6 +79,7 @@ static void photo_booth_led_init (PhotoBoothLed *led) tty.c_lflag |= ICANON; tty.c_oflag &= ~OPOST; tcsetattr(led->fd, TCSANOW, &tty); + tcsetattr(led->fd, TCSAFLUSH, &tty); char tempbuf[32]; int n = read (led->fd, tempbuf, sizeof(tempbuf)-1); GST_WARNING_OBJECT(led, "read %i bytes: '%s'", n, tempbuf); diff --git a/photoboothled.h b/photoboothled.h index 93df161..6c6b5fa 100644 --- a/photoboothled.h +++ b/photoboothled.h @@ -16,6 +16,7 @@ #ifndef __PHOTO_BOOTH_LED_H__ #define __PHOTO_BOOTH_LED_H__ +#include #include #define LED_BLACK 'b' @@ -42,7 +43,7 @@ struct _PhotoBoothLed struct _PhotoBoothLedClass { - GtkApplicationClass parent_class; + GObjectClass parent_class; }; GType photo_booth_led_get_type (void);