summaryrefslogtreecommitdiff
path: root/src/protocols/netbios/netbios.h
diff options
context:
space:
mode:
authorAndrew Shadura <andrewsh@debian.org>2016-12-15 11:12:46 +0100
committerAndrew Shadura <andrewsh@debian.org>2016-12-15 11:14:48 +0100
commitccc154b9b1c7682a86f8372070095e5e4218e7be (patch)
tree7b29d1db2daba9400ba6f55e660bd41da3c848e2 /src/protocols/netbios/netbios.h
parentf60c749375b9518e01cff9b0458234c65194df80 (diff)
parent50a11af5bddcda9160d84f2ae3577df7451a7a95 (diff)
Merge tag 'upstream/0.4.3.1'
Upstream version 0.4.3.1
Diffstat (limited to 'src/protocols/netbios/netbios.h')
-rw-r--r--src/protocols/netbios/netbios.h17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/protocols/netbios/netbios.h b/src/protocols/netbios/netbios.h
index 9fd5bd3..c3f40f7 100644
--- a/src/protocols/netbios/netbios.h
+++ b/src/protocols/netbios/netbios.h
@@ -22,8 +22,8 @@
#ifndef NETBIOS_HEADER_H
#define NETBIOS_HEADER_H
//------------------------------------------------------------------------------
-#include <stdlib.h>
#include <cstdint>
+#include <cstdlib>
//------------------------------------------------------------------------------
namespace NST
{
@@ -31,15 +31,14 @@ namespace protocols
{
namespace NetBIOS
{
-
/*! \class NetBIOS message header in SMB-direct case
*/
struct RawMessageHeader
{
- uint8_t _start;//!< In SMB direct always 0x00
- uint8_t _;
- uint16_t length;//!< Packet length
-} __attribute__ ((__packed__));
+ uint8_t _start; //!< In SMB direct always 0x00
+ uint8_t _;
+ uint16_t length; //!< Packet length
+} __attribute__((__packed__));
/*! \class NetBIOS message header wrapper
*/
@@ -55,8 +54,8 @@ struct MessageHeader : private RawMessageHeader
*/
inline const struct MessageHeader* get_header(const uint8_t* data)
{
- const MessageHeader* header (reinterpret_cast<const MessageHeader*>(data));
- if (header->start() == 0x00)
+ const MessageHeader* header(reinterpret_cast<const MessageHeader*>(data));
+ if(header->start() == 0x00)
{
return header;
}
@@ -67,5 +66,5 @@ inline const struct MessageHeader* get_header(const uint8_t* data)
} // namespace protocols
} // namespace NST
//------------------------------------------------------------------------------
-#endif//NETBIOS_HEADER_H
+#endif // NETBIOS_HEADER_H
//------------------------------------------------------------------------------