okssystem
Unit Tests
No unit tests written.
Clang Formatting
| File | Status |
|---|---|
| include/okssystem/Descriptor.hpp | ❌ Needs formatting |
| include/okssystem/Environment.hpp | ❌ Needs formatting |
| include/okssystem/Executable.hpp | ❌ Needs formatting |
| include/okssystem/FIFOConnection.hpp | ❌ Needs formatting |
| include/okssystem/File.hpp | ❌ Needs formatting |
| include/okssystem/Host.hpp | ❌ Needs formatting |
| include/okssystem/MapFile.hpp | ❌ Needs formatting |
| include/okssystem/OksSystem.hpp | ❌ Needs formatting |
| include/okssystem/Path.hpp | ❌ Needs formatting |
| include/okssystem/Process.hpp | ❌ Needs formatting |
| include/okssystem/StringMemoryArea.hpp | ❌ Needs formatting |
| include/okssystem/User.hpp | ❌ Needs formatting |
| include/okssystem/exceptions.hpp | ❌ Needs formatting |
| src/Descriptor.cpp | ❌ Needs formatting |
| src/Environment.cpp | ❌ Needs formatting |
| src/Executable.cpp | ❌ Needs formatting |
| src/FIFOConnection.cpp | ❌ Needs formatting |
| src/File.cpp | ❌ Needs formatting |
| src/Host.cpp | ❌ Needs formatting |
| src/MapFile.cpp | ❌ Needs formatting |
| src/Path.cpp | ❌ Needs formatting |
| src/Process.cpp | ❌ Needs formatting |
| src/StringMemoryArea.cpp | ❌ Needs formatting |
| src/User.cpp | ❌ Needs formatting |
include/okssystem/Descriptor.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_DESCRIPTOR_HPP_
- Line 68: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_DESCRIPTOR_HPP_"
- Line 66: Namespace should be terminated with '// namespace OksSystem '
include/okssystem/Environment.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_ENVIRONMENT_HPP_
- Line 36: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_ENVIRONMENT_HPP_"
- Line 34: Namespace should be terminated with '// namespace OksSystem '
include/okssystem/Executable.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_EXECUTABLE_HPP_
- Line 70: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_EXECUTABLE_HPP_"
- Line 21: Found other header after system header. Should be: Executable.hh, other non-system headers, system headers.
- Line 22: Found other header after system header. Should be: Executable.hh, other non-system headers, system headers.
- Line 45: Access specifier "public" has already appeared in class Executable
- Line 48: Single-parameter constructors should be marked explicit.
- Line 49: Single-parameter constructors should be marked explicit.
- Line 50: Single-parameter constructors should be marked explicit.
- Line 68: Namespace should be terminated with '// namespace OksSystem '
- Line 64: Add #include
for string
include/okssystem/FIFOConnection.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_FIFOCONNECTION_HPP_
- Line 60: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_FIFOCONNECTION_HPP_"
- Line 34: Single-parameter constructors should be marked explicit.
- Line 35: Single-parameter constructors should be marked explicit.
- Line 58: Namespace should be terminated with '// namespace OksSystem '
- Line 48: Add #include
for string
include/okssystem/File.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_FILE_HPP_
- Line 127: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_FILE_HPP_"
- Line 24: Found other header after system header. Should be: File.hh, other non-system headers, system headers.
- Line 49: Access specifier "public" has already appeared in class File
- Line 71: Single-parameter constructors should be marked explicit.
- Line 72: Single-parameter constructors should be marked explicit.
- Line 120: Namespace should be terminated with '// namespace OksSystem '
include/okssystem/Host.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_HOST_HPP_
- Line 101: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_HOST_HPP_"
- Line 38: Access specifier "public:" appears after one (or both) of "private:" and/or "protected:", not before
- Line 44: Single-parameter constructors should be marked explicit.
- Line 45: Single-parameter constructors should be marked explicit.
- Line 76: Access specifier "public:" appears after one (or both) of "private:" and/or "protected:", not before
- Line 96: Namespace should be terminated with '// namespace OksSystem '
include/okssystem/MapFile.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_MAPFILE_HPP_
- Line 75: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_MAPFILE_HPP_"
- Line 73: Namespace should be terminated with '// namespace OksSystem '
- Line 35: Add #include
for string
include/okssystem/OksSystem.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 0: No #ifndef header guard found, suggested CPP variable is: OKSSYSTEM_INCLUDE_OKSSYSTEM_OKSSYSTEM_HPP_
include/okssystem/Path.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_PATH_HPP_
- Line 50: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_PATH_HPP_"
- Line 35: Access specifier "public:" appears after one (or both) of "private:" and/or "protected:", not before
- Line 39: Single-parameter constructors should be marked explicit.
- Line 46: Namespace should be terminated with '// namespace OksSystem '
- Line 44: Add #include
for string
include/okssystem/Process.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_PROCESS_HPP_
- Line 68: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_PROCESS_HPP_"
- Line 42: Access specifier "public:" appears after one (or both) of "private:" and/or "protected:", not before
- Line 49: Single-parameter constructors should be marked explicit.
- Line 62: Namespace should be terminated with '// namespace OksSystem '
include/okssystem/StringMemoryArea.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_STRINGMEMORYAREA_HPP_
- Line 64: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_STRINGMEMORYAREA_HPP_"
- Line 48: Access specifier "public" has already appeared in class StringMemoryArea
- Line 62: Namespace should be terminated with '// namespace OksSystem '
- Line 39: Add #include
for string
include/okssystem/User.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 15: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_USER_HPP_
- Line 65: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_USER_HPP_"
- Line 39: Access specifier "public:" appears after one (or both) of "private:" and/or "protected:", not before
- Line 42: Single-parameter constructors should be marked explicit.
- Line 43: Single-parameter constructors should be marked explicit.
- Line 56: Namespace should be terminated with '// namespace OksSystem '
include/okssystem/exceptions.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 9: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 6: #ifndef header guard has wrong style, please use: OKSSYSTEM_INCLUDE_OKSSYSTEM_EXCEPTIONS_HPP_
- Line 145: #endif line should be "#endif // OKSSYSTEM_INCLUDE_OKSSYSTEM_EXCEPTIONS_HPP_"
- Line 39: Using C-style cast. Use static_cast
(...) instead - Line 46: Using C-style cast. Use static_cast
(...) instead - Line 47: Using C-style cast. Use static_cast
(...) instead - Line 54: Using C-style cast. Use static_cast
(...) instead - Line 56: Using C-style cast. Use static_cast
(...) instead - Line 63: Using C-style cast. Use static_cast
(...) instead - Line 64: Using C-style cast. Use static_cast
(...) instead - Line 71: Using C-style cast. Use static_cast
(...) instead - Line 72: Using C-style cast. Use static_cast
(...) instead - Line 79: Using C-style cast. Use static_cast
(...) instead - Line 81: Using C-style cast. Use static_cast
(...) instead - Line 88: Using C-style cast. Use static_cast
(...) instead - Line 97: Using C-style cast. Use static_cast
(...) instead - Line 105: Using C-style cast. Use static_cast
(...) instead - Line 113: Using C-style cast. Use static_cast
(...) instead - Line 121: Using C-style cast. Use static_cast
(...) instead - Line 129: Using C-style cast. Use static_cast
(...) instead - Line 137: Using C-style cast. Use static_cast
(...) instead - Line 142: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
src/Descriptor.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 20: Found other header after system header. Should be: Descriptor.hh, other non-system headers, system headers.
- Line 138: Add #include
for string
Warnings
- Line 43: do not declare C-style arrays, use std::array<> instead
- Line 44: do not declare C-style arrays, use std::array<> instead
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 101: narrowing conversion from 'ssize_t' (aka 'long') to signed type 'int' is implementation-defined
- Line 108: narrowing conversion from 'ssize_t' (aka 'long') to signed type 'int' is implementation-defined
src/Environment.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 57: Add #include
for string - Line 44: Add #include
Warnings
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 15: inclusion of deprecated C++ header 'stdlib.h'; consider using 'cstdlib' instead
- Line 44: use auto when declaring iterators
- Line 56: use nullptr
src/Executable.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 269: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 277: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 27: Found other header after system header. Should be: Executable.hh, other non-system headers, system headers.
- Line 28: Found other header after system header. Should be: Executable.hh, other non-system headers, system headers.
- Line 30: Found other header after system header. Should be: Executable.hh, other non-system headers, system headers.
- Line 102: Using C-style cast. Use one of the C++ cast operators instead
- Line 154: Using C-style cast. Use one of the C++ cast operators instead
- Line 178: Using C-style cast. Use one of the C++ cast operators instead
- Line 225: Use of NULL #define found; prefer using the nullptr keyword
- Line 243: Use of NULL #define found; prefer using the nullptr keyword
- Line 250: Use of NULL #define found; prefer using the nullptr keyword
- Line 280: Use of NULL #define found; prefer using the nullptr keyword
- Line 298: Use of NULL #define found; prefer using the nullptr keyword
- Line 304: Use of NULL #define found; prefer using the nullptr keyword
- Line 319: Use int16/int64/etc, rather than the C type long
- Line 321: Use int16/int64/etc, rather than the C type long
- Line 323: Using C-style cast. Use static_cast
(...) instead - Line 356: Use of NULL #define found; prefer using the nullptr keyword
- Line 378: Use of NULL #define found; prefer using the nullptr keyword
- Line 406: Use of NULL #define found; prefer using the nullptr keyword
- Line 450: Use of NULL #define found; prefer using the nullptr keyword
- Line 478: Use of NULL #define found; prefer using the nullptr keyword
- Line 484: Use of NULL #define found; prefer using the nullptr keyword
- Line 518: Use of NULL #define found; prefer using the nullptr keyword
- Line 546: Use of NULL #define found; prefer using the nullptr keyword
- Line 552: Use of NULL #define found; prefer using the nullptr keyword
- Line 579: Use of NULL #define found; prefer using the nullptr keyword
- Line 597: Use of NULL #define found; prefer using the nullptr keyword
- Line 603: Use of NULL #define found; prefer using the nullptr keyword
- Line 614: Add #include
for string - Line 53: Add #include
for vector<>
Warnings
- Line 43: do not declare C-style arrays, use std::array<> instead
- Line 44: do not declare C-style arrays, use std::array<> instead
- Line 34: do not declare C-style arrays, use std::array<> instead
- Line 35: do not declare C-style arrays, use std::array<> instead
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 16: inclusion of deprecated C++ header 'signal.h'; consider using 'csignal' instead
- Line 54: use emplace_back instead of push_back
- Line 75: do not use pointer arithmetic
- Line 90: do not use pointer arithmetic
- Line 102: do not use C-style cast to convert between unrelated types
- Line 102: C-style casts are discouraged; use static_cast
- Line 102: do not manage memory manually; consider a container or a smart pointer
- Line 105: do not use pointer arithmetic
- Line 106: do not use pointer arithmetic
- Line 108: do not use pointer arithmetic
- Line 110: do not use pointer arithmetic
- Line 110: use nullptr
- Line 115: do not use pointer arithmetic
- Line 115: use nullptr
- Line 116: do not manage memory manually; use RAII
- Line 116: do not use pointer arithmetic
- Line 118: do not manage memory manually; use RAII
- Line 122: do not use pointer arithmetic
- Line 122: use nullptr
- Line 123: do not manage memory manually; use RAII
- Line 123: do not use pointer arithmetic
- Line 125: do not manage memory manually; use RAII
- Line 142: use auto when declaring iterators
- Line 143: use auto when declaring iterators
- Line 149: do not use pointer arithmetic
- Line 150: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119
- Line 150: do not use pointer arithmetic
- Line 154: do not use pointer arithmetic
- Line 154: C-style casts are discouraged; use static_cast/const_cast/reinterpret_cast
- Line 154: use nullptr
- Line 163: do not use pointer arithmetic
- Line 164: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119
- Line 164: do not use pointer arithmetic
- Line 166: use auto when declaring iterators
- Line 167: use auto when declaring iterators
- Line 173: do not use pointer arithmetic
- Line 174: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119
- Line 174: do not use pointer arithmetic
- Line 178: do not use pointer arithmetic
- Line 178: C-style casts are discouraged; use static_cast/const_cast/reinterpret_cast
- Line 178: use nullptr
- Line 188: do not use pointer arithmetic
- Line 193: do not use pointer arithmetic
- Line 198: thrown exception type is not nothrow copy constructible
- Line 225: use nullptr
- Line 243: use nullptr
- Line 250: use nullptr
- Line 280: use nullptr
- Line 298: use nullptr
- Line 304: use nullptr
- Line 318: do not declare C-style arrays, use std::array<> instead
- Line 319: consider replacing 'long' with 'int64'
- Line 323: redundant cast to the same type
- Line 323: do not use array subscript when the index is not an integer constant expression
- Line 332: do not declare C-style arrays, use std::array<> instead
- Line 333: do not declare C-style arrays, use std::array<> instead
- Line 334: do not declare C-style arrays, use std::array<> instead
- Line 356: use nullptr
- Line 378: use nullptr
- Line 401: Value stored to 'error_str' during its initialization is never read
- Line 406: use nullptr
- Line 450: use nullptr
- Line 478: use nullptr
- Line 484: use nullptr
- Line 518: use nullptr
- Line 546: use nullptr
- Line 552: use nullptr
- Line 579: use nullptr
- Line 597: use nullptr
- Line 603: use nullptr
- Line 617: use auto when declaring iterators
src/FIFOConnection.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 17: Found other header after system header. Should be: FIFOConnection.hh, other non-system headers, system headers.
- Line 42: The delete operator appears to be used; owning memory should be done with a smart pointer rather than a raw pointer
- Line 146: The delete operator appears to be used; owning memory should be done with a smart pointer rather than a raw pointer
- Line 177: The delete operator appears to be used; owning memory should be done with a smart pointer rather than a raw pointer
- Line 207: The delete operator appears to be used; owning memory should be done with a smart pointer rather than a raw pointer
- Line 224: The delete operator appears to be used; owning memory should be done with a smart pointer rather than a raw pointer
- Line 120: Add #include
for string
Warnings
- Line 43: do not declare C-style arrays, use std::array<> instead
- Line 44: do not declare C-style arrays, use std::array<> instead
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 30: use nullptr
- Line 37: use nullptr
- Line 60: do not declare C-style arrays, use std::array<> instead
- Line 65: do not use array subscript when the index is not an integer constant expression
- Line 112: do not declare C-style arrays, use std::array<> instead
- Line 117: do not use array subscript when the index is not an integer constant expression
- Line 147: use nullptr
- Line 178: use nullptr
- Line 208: use nullptr
- Line 225: use nullptr
src/File.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 18: "unistd.h" already included at sourcecode/okssystem/src/File.cpp:15
- Line 31: Found other header after system header. Should be: File.hh, other non-system headers, system headers.
- Line 38: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 47: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 48: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 49: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 50: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 51: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 53: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 54: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 55: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 807: Add #include
for string
Warnings
- Line 43: do not declare C-style arrays, use std::array<> instead
- Line 44: do not declare C-style arrays, use std::array<> instead
- Line 34: do not declare C-style arrays, use std::array<> instead
- Line 35: do not declare C-style arrays, use std::array<> instead
- Line 44: definition of implicit copy assignment operator for 'User' is deprecated because it has a user-provided copy constructor
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 16: inclusion of deprecated C++ header 'stdio.h'; consider using 'cstdio' instead
- Line 20: inclusion of deprecated C++ header 'errno.h'; consider using 'cerrno' instead
- Line 21: inclusion of deprecated C++ header 'assert.h'; consider using 'cassert' instead
- Line 38: macro 'SPACE_CHAR' used to declare a constant; consider using a 'constexpr' constant
- Line 40: do not declare C-style arrays, use std::array<> instead
- Line 41: do not declare C-style arrays, use std::array<> instead
- Line 53: macro 'SLASH_CHAR' used to declare a constant; consider using a 'constexpr' constant
- Line 54: macro 'COLON_CHAR' used to declare a constant; consider using a 'constexpr' constant
- Line 55: macro 'DOT_CHAR' used to declare a constant; consider using a 'constexpr' constant
- Line 166: The 1st argument to 'getcwd' is NULL but should not be NULL
- Line 166: use nullptr
- Line 169: do not manage memory manually; use RAII
- Line 211: do not declare C-style arrays, use std::array<> instead
- Line 212: do not use pointer arithmetic
- Line 212: do not use pointer arithmetic
- Line 213: do not use pointer arithmetic
- Line 213: do not use pointer arithmetic
- Line 214: do not use pointer arithmetic
- Line 214: do not use pointer arithmetic
- Line 215: do not use pointer arithmetic
- Line 215: do not use pointer arithmetic
- Line 216: do not use pointer arithmetic
- Line 216: do not use pointer arithmetic
- Line 217: do not use pointer arithmetic
- Line 217: do not use pointer arithmetic
- Line 218: do not use pointer arithmetic
- Line 218: do not use pointer arithmetic
- Line 219: do not use pointer arithmetic
- Line 219: do not use pointer arithmetic
- Line 220: do not use pointer arithmetic
- Line 220: do not use pointer arithmetic
- Line 221: do not use pointer arithmetic
- Line 221: do not use pointer arithmetic
- Line 285: do not use array subscript when the index is not an integer constant expression
- Line 400: do not declare C-style arrays, use std::array<> instead
- Line 402: use nullptr
- Line 467: do not manage memory manually; use RAII
- Line 608: use emplace_back instead of push_back
- Line 673: use auto when declaring iterators
- Line 674: the const qualified variable 'f' is copy-constructed from a const reference; consider making it a const reference
- Line 822: use auto when initializing with new to avoid duplicating the type name
- Line 843: use auto when initializing with new to avoid duplicating the type name
src/Host.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 29: #define appears to be used. Macros should generally be avoided if there's an alternative to them.
- Line 46: Using C-style cast. Use one of the C++ cast operators instead
- Line 308: Add #include
for string
Warnings
- Line 29: macro 'BUFFER_SIZE' used to declare a constant; consider using a 'constexpr' constant
- Line 38: variable 'info_ptr' is not initialized
- Line 40: use nullptr
- Line 40: use nullptr
- Line 42: The bzero() function is obsoleted by memset()
- Line 46: use auto when initializing with a cast to avoid duplicating the type name
- Line 46: do not use C-style cast to convert between unrelated types
- Line 46: C-style casts are discouraged; use reinterpret_cast
- Line 59: do not declare C-style arrays, use std::array<> instead
- Line 60: use auto when initializing with a cast to avoid duplicating the type name
- Line 60: do not use C-style cast to convert between unrelated types
- Line 60: C-style casts are discouraged; use reinterpret_cast
- Line 61: use nullptr
- Line 199: use nullptr
- Line 227: use nullptr
- Line 248: do not declare C-style arrays, use std::array<> instead
src/MapFile.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 101: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 21: Found other header after system header. Should be: MapFile.hh, other non-system headers, system headers.
- Line 115: Add #include
for string
Warnings
- Line 43: do not declare C-style arrays, use std::array<> instead
- Line 44: do not declare C-style arrays, use std::array<> instead
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 47: use nullptr
- Line 48: use nullptr
- Line 56: use nullptr
- Line 78: use nullptr
- Line 96: use nullptr
- Line 97: use nullptr
- Line 131: do not manage memory manually; consider a container or a smart pointer
- Line 135: do not manage memory manually; use RAII
- Line 163: use nullptr
src/Path.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 119: If/else bodies with multiple statements require braces
- Line 116: Add #include
for string
Warnings
- Line 43: do not declare C-style arrays, use std::array<> instead
- Line 44: do not declare C-style arrays, use std::array<> instead
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 89: use auto when declaring iterators
- Line 117: use auto when declaring iterators
src/Process.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 208: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 220: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 23: Found other header after system header. Should be: Process.hh, other non-system headers, system headers.
- Line 25: Found other header after system header. Should be: Process.hh, other non-system headers, system headers.
- Line 237: Add #include
for string
Warnings
- Line 34: do not declare C-style arrays, use std::array<> instead
- Line 35: do not declare C-style arrays, use std::array<> instead
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 34: do not declare C-style arrays, use std::array<> instead
- Line 36: do not declare C-style arrays, use std::array<> instead
- Line 39: use nullptr
- Line 49: do not use array subscript when the index is not an integer constant expression
- Line 50: do not use array subscript when the index is not an integer constant expression
- Line 51: use nullptr
- Line 78: use nullptr
- Line 153: variable 'status' is not initialized
- Line 217: redundant return statement at the end of a function with a void return type
src/StringMemoryArea.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 16: Found other header after system header. Should be: StringMemoryArea.hh, other non-system headers, system headers.
- Line 20: Using C-style cast. Use static_cast
(...) instead - Line 21: Using C-style cast. Use static_cast
(...) instead - Line 68: Use of NULL #define found; prefer using the nullptr keyword
- Line 202: Add #include
for string
Warnings
- Line 35: 'OksSystem::StringMemoryArea' has virtual functions but non-virtual destructor
- Line 20: C-style casts are discouraged; use static_cast
- Line 21: C-style casts are discouraged; use static_cast
- Line 37: do not use pointer arithmetic
- Line 38: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119
- Line 51: do not use pointer arithmetic
- Line 52: do not use pointer arithmetic
- Line 65: use nullptr
- Line 68: use nullptr
- Line 69: use nullptr
- Line 71: do not use pointer arithmetic
- Line 90: do not use pointer arithmetic
- Line 91: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119
- Line 119: use nullptr
- Line 187: use nullptr
src/User.cpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 20: Found other header after system header. Should be: User.hh, other non-system headers, system headers.
- Line 38: Use int16/int64/etc, rather than the C type long
- Line 114: Use int16/int64/etc, rather than the C type long
- Line 160: Use int16/int64/etc, rather than the C type long
- Line 255: Add #include
for string
Warnings
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 38: consider replacing 'long' with 'int64'
- Line 50: variable 'result' is not initialized
- Line 55: use nullptr
- Line 114: consider replacing 'long' with 'int64'
- Line 127: variable 'result' is not initialized
- Line 132: use nullptr
- Line 160: consider replacing 'long' with 'int64'
- Line 174: variable 'result' is not initialized
- Line 178: use nullptr
- Line 254: use auto when initializing with a cast to avoid duplicating the type name
- Line 254: C-style casts are discouraged; use static_cast (if needed, the cast may be redundant)
- Line 255: the const qualified variable 'name' is copy-constructed from a const reference; consider making it a const reference
test/apps/OksSystemTest.cxx
Errors
- Line 0: The standard copyright message wasn't found.
- Line 1: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 18: Found other header after system header. Should be: OksSystemTest.hh, other non-system headers, system headers.
- Line 19: Found other header after system header. Should be: OksSystemTest.hh, other non-system headers, system headers.
- Line 21: Found other header after system header. Should be: OksSystemTest.hh, other non-system headers, system headers.
- Line 22: Found other header after system header. Should be: OksSystemTest.hh, other non-system headers, system headers.
- Line 71: Using C-style cast. Use one of the C++ cast operators instead
- Line 92: "cout" should not be used for output in DUNE DAQ software.
- Line 93: "cout" should not be used for output in DUNE DAQ software.
- Line 94: "cout" should not be used for output in DUNE DAQ software.
- Line 95: "cout" should not be used for output in DUNE DAQ software.
- Line 112: "cout" should not be used for output in DUNE DAQ software.
- Line 117: "cout" should not be used for output in DUNE DAQ software.
- Line 103: Add #include
for string - Line 55: Add #include
for vector<>
Warnings
- Line 43: do not declare C-style arrays, use std::array<> instead
- Line 44: do not declare C-style arrays, use std::array<> instead
- Line 34: do not declare C-style arrays, use std::array<> instead
- Line 35: do not declare C-style arrays, use std::array<> instead
- Line 142: function-like macro 'OKSSYSTEM_ALLOC_CHECK' used; consider a 'constexpr' template function
- Line 71: do not use C-style cast to convert between unrelated types
- Line 71: C-style casts are discouraged; use static_cast
- Line 71: do not manage memory manually; consider a container or a smart pointer
- Line 73: do not use pointer arithmetic
- Line 124: do not use pointer arithmetic
test/apps/OksSystemTest.hpp
Errors
- Line 0: The standard copyright message wasn't found.
- Line 6: C-style comment syntax detected; please use either C++ style "//" or Doxygen style
- Line 0: No #ifndef header guard found, suggested CPP variable is: OKSSYSTEM_TEST_APPS_OKSSYSTEMTEST_HPP_