Mingjie Shen
Mingjie Shen
I'm not sure if we need check return values of the following functions for null. These functions are checked for null in most cases (70%+). https://github.com/libsdl-org/SDL/blob/a4604cb0d616db97921a2674a63b45f3fdfb81bc/src/video/x11/SDL_x11modes.c#L407 https://github.com/libsdl-org/SDL/blob/a4604cb0d616db97921a2674a63b45f3fdfb81bc/src/video/wayland/SDL_waylandvideo.c#L552 https://github.com/libsdl-org/SDL/blob/a4604cb0d616db97921a2674a63b45f3fdfb81bc/src/video/wayland/SDL_waylandvideo.c#L616 https://github.com/libsdl-org/SDL/blob/a4604cb0d616db97921a2674a63b45f3fdfb81bc/src/video/x11/SDL_x11mouse.c#L308
https://github.com/cosmos72/twin/blob/b6e4e4bbae457447792a6d7b899e966c2b6571be/server/resize.cpp#L127-L129 This allocation size is derived from user input and the multiplication might overflow. Consider adding upper bounds for x and y, e.g. ``` C if (x > 0 &&...
CreateAuth() opens a file and then, if the opening was successful, its permissions are changed with chmod. However, an attacker might change the target of the file name between the...
The 'const' modifier has no effect on return types. The 'const' modifying the return type can be removed.
Logical NOT (!) has higher precedence than bitwise AND (&).
Function bt_system_init should return a value of type BT_ERROR but does not return a value here https://github.com/jameswalmsley/bitthunder/blob/cb92284a5be2e867c507a90fb14ac9a99120e2ae/os/src/bt_main.c#L89-L93
https://github.com/jameswalmsley/bitthunder/blob/cb92284a5be2e867c507a90fb14ac9a99120e2ae/os/src/process/bt_threads.c#L85
In the following code snippet, the pointer `al` is checked for nullness after is has already been dereferenced. Should we move the check before the dereference? https://github.com/gozfree/gear-lib/blob/5e1947fd7b86bad1c1ed9d9ce36591585e396793/gear-lib/libsock/libsock.c#L548-L551 https://github.com/gozfree/gear-lib/blob/5e1947fd7b86bad1c1ed9d9ce36591585e396793/gear-lib/libsock/libsock.c#L586-L589
``` [build-stdout] ==== build linux libhash start... [build-stderr] /usr/bin/ld: cannot find -lstrex [build-stderr] collect2: error: ld returned 1 exit status [build-stderr] make: *** [Makefile:91: test_libhash] Error 1 ``` It seems...