clang-tidy: Replaced C-Style Casts with C++-Style

Resolved the following style warnings by replacing C-style casts
with appropriate C++-style casts

'''
    frup.cpp:193:34: style: C-style pointer casting [cstyleCast]
        const uint8_t* areabufptr = (const uint8_t*)areabuf;
                                     ^
    frup.cpp:255:34: style: C-style pointer casting [cstyleCast]
        const uint8_t* areabufptr = (const uint8_t*)areabuf;
                                     ^
    frup.cpp:333:34: style: C-style pointer casting [cstyleCast]
        const uint8_t* areabufptr = (const uint8_t*)areabuf;
                                     ^
    frup.cpp:463:34: style: C-style pointer casting [cstyleCast]
        const uint8_t* areabufptr = (const uint8_t*)areabuf;
                                     ^
    frup.cpp:611:26: style: C-style pointer casting [cstyleCast]
        char* bin_in_ascii = (char*)malloc(bin_in_ascii_len);
                             ^
    frup.cpp:616:24: style: C-style pointer casting [cstyleCast]
        char* bin_copy = &((char*)bin_in_ascii)[2];
                           ^
    frup.cpp:710:17: style: C-style pointer casting [cstyleCast]
                    (uint8_t*)msgbuf + 2, len, &chassis_type,
                    ^
    6/7 files checked 0% done
    frup.cpp:737:17: style: C-style pointer casting [cstyleCast]
                    (uint8_t*)msgbuf + 2, len, nullptr, &mfg_date_time,
                    ^
    frup.cpp:769:17: style: C-style pointer casting [cstyleCast]
                    (uint8_t*)msgbuf + 2, len, nullptr,
'''

Change-Id: Ifa13f8e5033ab09710ac6c7fa329396984947fc8
Signed-off-by: Jayanth Othayoth <ojayanth@gmail.com>
1 file changed
tree: f0d6097ef03932bc31cd73acddaac6fe2476c400
  1. scripts/
  2. subprojects/
  3. .clang-format
  4. .gitignore
  5. fru_area.cpp
  6. fru_area.hpp
  7. frup.cpp
  8. frup.hpp
  9. LICENSE
  10. meson.build
  11. meson.options
  12. OWNERS
  13. readeeprom.cpp
  14. README.md
  15. strgfnhandler.cpp
  16. types.hpp
  17. writefrudata.cpp
  18. writefrudata.hpp
README.md

ipmi-fru-parser

Building

To build this package, do the following steps:

meson setup builddir
ninja -C builddir