diff options
author | RALOVICH, Kristof <tade60@freemail.hu> | 2014-08-17 15:01:09 +0200 |
---|---|---|
committer | RALOVICH, Kristof <tade60@freemail.hu> | 2014-08-17 15:01:09 +0200 |
commit | 89d360e47d0ad3734a70dca539a02b1ff28774d0 (patch) | |
tree | bcecc244f2a2e8151c48b5ca1957163ac24382ce /src | |
parent | 8ccfcb10c9d2f6d6e0dc52e49e550438d3efe14b (diff) |
kfreebsd build fixes
Diffstat (limited to 'src')
-rw-r--r-- | src/Log.hpp | 2 | ||||
-rw-r--r-- | src/gant/gant.c | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/Log.hpp b/src/Log.hpp index f2c1f72..abb3639 100644 --- a/src/Log.hpp +++ b/src/Log.hpp @@ -29,7 +29,7 @@ # include <crtdbg.h> # include <io.h> #endif -#if defined(__linux__) || defined(__GNU__) || defined(__FreeBSD__) +#if defined(__linux__) || defined(__GNU__) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) # include <unistd.h> #endif #include <iostream> diff --git a/src/gant/gant.c b/src/gant/gant.c index b146665..1c4cca6 100644 --- a/src/gant/gant.c +++ b/src/gant/gant.c @@ -110,7 +110,7 @@ uint isa405; uint waitauth; int nphase0; char modelname[256]; -char devname[256]; +char deviname[256]; ushort part = 0; ushort ver = 0; uint unitid = 0; @@ -230,7 +230,7 @@ void print_tcx_footer(xmlTextWriterPtr tcxfile) rc = xmlTextWriterEndElement(tcxfile); XML_ERROR_CHECK; /* Lap (Is it a good idea to do it here?) */ rc = xmlTextWriterStartElement(tcxfile, BAD_CAST "Creator"); XML_ERROR_CHECK; rc = xmlTextWriterWriteAttribute(tcxfile, BAD_CAST "xsi:type", BAD_CAST "Device_t"); XML_ERROR_CHECK; - rc = xmlTextWriterWriteFormatElement(tcxfile, BAD_CAST "Name", "%s", devname); XML_ERROR_CHECK; + rc = xmlTextWriterWriteFormatElement(tcxfile, BAD_CAST "Name", "%s", deviname); XML_ERROR_CHECK; rc = xmlTextWriterWriteFormatElement(tcxfile, BAD_CAST "UnitId", "%u", unitid); XML_ERROR_CHECK; rc = xmlTextWriterWriteFormatElement(tcxfile, BAD_CAST "ProductID", "%u", part); XML_ERROR_CHECK; rc = xmlTextWriterStartElement(tcxfile, BAD_CAST "Version"); XML_ERROR_CHECK; @@ -388,9 +388,9 @@ void decode(ushort bloblen, ushort pkttype, ushort pktlen, int dsize, uchar * da dump_data(stderr, data+doff, 0, pktlen); break; case 525: - memset(devname, 0, sizeof devname); - memcpy(devname, data + doff, pktlen); - DEBUG_OUT(1, "Packet %d: Devname: \"%s\"", pkttype, devname); + memset(deviname, 0, sizeof deviname); + memcpy(deviname, data + doff, pktlen); + DEBUG_OUT(1, "Packet %d: Devname: \"%s\"", pkttype, deviname); break; case 12: DEBUG_OUT(1, "Packet %d: xfer complete (subtype %u)", pkttype, data[doff] + data[doff + 1] * 256); |