repositories
/
deb_libcec.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
cec: send opcode_image_view_on instead of text_view_on
[deb_libcec.git]
/
src
/
lib
/
platform
/
baudrate.h
diff --git
a/src/lib/platform/baudrate.h
b/src/lib/platform/baudrate.h
index 53f04acf2a0505b2dc318926b2d3709a85d97a07..759b1f1495c3a78389757f99ea60cdb544e3035c 100644
(file)
--- a/
src/lib/platform/baudrate.h
+++ b/
src/lib/platform/baudrate.h
@@
-21,14
+21,18
@@
//every baudrate I could find is in here in an #ifdef block
//so it should compile on everything
//every baudrate I could find is in here in an #ifdef block
//so it should compile on everything
+#include "os-dependent.h"
+
+#ifndef __WINDOWS__
#include <termios.h>
#include <termios.h>
+#endif
namespace CEC
{
static struct sbaudrate
{
namespace CEC
{
static struct sbaudrate
{
- int rate;
- int symbol;
+ int
32_t
rate;
+ int
32_t
symbol;
}
baudrates[] =
{
}
baudrates[] =
{
@@
-182,11
+186,11
@@
namespace CEC
{ -1, -1}
};
{ -1, -1}
};
- static int
IntToBaudrate(in
t baudrate)
+ static int
32_t IntToBaudrate(uint32_
t baudrate)
{
for (unsigned int i = 0; i < sizeof(baudrates) / sizeof(CEC::sbaudrate) - 1; i++)
{
{
for (unsigned int i = 0; i < sizeof(baudrates) / sizeof(CEC::sbaudrate) - 1; i++)
{
- if (baudrates[i].rate == baudrate)
+ if (baudrates[i].rate ==
(int32_t)
baudrate)
return baudrates[i].symbol;
}
return baudrates[i].symbol;
}