Fix build errors on Windows.

This commit is contained in:
Daniel Beer 2014-03-08 17:55:07 +13:00
parent a69609a7d1
commit 2c7df22f4a
2 changed files with 2 additions and 9 deletions

View File

@ -551,16 +551,8 @@ static int flash_bsl_writemem(device_t dev_base,
static int enter_via_dtr_rts(struct flash_bsl_device *dev)
{
sport_t fd = dev->serial_fd;
int status;
int status = SPORT_MC_RTS;
if (ioctl(fd, TIOCMGET, &status) == -1)
{
perror("Read Port Error\n");
return -1;
}
status &= ~SPORT_MC_DTR;
status |= SPORT_MC_RTS;
if (sport_set_modem(fd, status) != 0)
{
return -1;

View File

@ -19,6 +19,7 @@
#include <usb.h>
#include <stdlib.h>
#include <string.h>
#include <limits.h>
#include "usbutil.h"
#include "output.h"
#include "output_util.h"