[mythtv-commits] [MythTV/mythtv] 2aa937: Fix pointer to integer (to pointer) casting warnin...
David Hampton
noreply at github.com
Mon Mar 27 21:32:49 UTC 2023
Branch: refs/heads/master
Home: https://github.com/MythTV/mythtv
Commit: 2aa937500f7c522a2cff53715a528411334952f6
https://github.com/MythTV/mythtv/commit/2aa937500f7c522a2cff53715a528411334952f6
Author: David Hampton <mythtv at love2code.net>
Date: 2023-03-27 (Mon, 27 Mar 2023)
Changed paths:
M mythtv/libs/libmyth/audio/audioconvert.cpp
Log Message:
-----------
Fix pointer to integer (to pointer) casting warnings in audioconvert.
Don't cast a pointer to an integer, add a number to it, and then cast
it back to a pointer. This transformation is not transparent to the
compiler, and it can lose potential optimizations chances. Instead
cast it to a pointer to a uint8_t (width of one byte) and then do the
addition directly to the pointer.
Commit: 9df365ed46fa20053e33ac48e278da06e285a6e5
https://github.com/MythTV/mythtv/commit/9df365ed46fa20053e33ac48e278da06e285a6e5
Author: David Hampton <mythtv at love2code.net>
Date: 2023-03-27 (Mon, 27 Mar 2023)
Changed paths:
M mythtv/libs/libmythtv/recorders/signalmonitor.cpp
Log Message:
-----------
Fix loss of precision warning in signalmonitor.cpp.
Casting from a pointer to a "long" is only valid if they contain the
same number of bits. Instead use the uintptr_t type, which is an
integer type that is guaranteed to have the same number of bits as a
pointer.
Commit: ec863c537b696ab9dba5fb1aee9dbad0fbd44e6a
https://github.com/MythTV/mythtv/commit/ec863c537b696ab9dba5fb1aee9dbad0fbd44e6a
Author: David Hampton <mythtv at love2code.net>
Date: 2023-03-27 (Mon, 27 Mar 2023)
Changed paths:
M mythtv/libs/libmythtv/recorders/RTjpegN.cpp
M mythtv/libs/libmythtv/recorders/RTjpegN.h
Log Message:
-----------
Use aligned new in RTjpeg.cpp instead of manual alignment.
This simplifies the code, as well as eliminating warnings about
casting pointers to integers and back to pointers.
Compare: https://github.com/MythTV/mythtv/compare/67833bcab241...ec863c537b69
More information about the mythtv-commits
mailing list