lint fixes

This commit is contained in:
Maxim Devaev
2024-03-01 00:43:57 +02:00
parent 2a37f1650b
commit c852e5f827
2 changed files with 9 additions and 9 deletions

View File

@@ -68,12 +68,12 @@ int us_unjpeg(const us_frame_s *src, us_frame_s *dest, bool decode) {
jpeg_start_decompress(&jpeg); jpeg_start_decompress(&jpeg);
US_FRAME_COPY_META(src, dest); US_FRAME_COPY_META(src, dest); // cppcheck-suppress redundantAssignment
dest->format = V4L2_PIX_FMT_RGB24; dest->format = V4L2_PIX_FMT_RGB24; // cppcheck-suppress redundantAssignment
dest->width = jpeg.output_width; dest->width = jpeg.output_width; // cppcheck-suppress redundantAssignment
dest->height = jpeg.output_height; dest->height = jpeg.output_height; // cppcheck-suppress redundantAssignment
dest->stride = jpeg.output_width * jpeg.output_components; // Row stride dest->stride = jpeg.output_width * jpeg.output_components; // cppcheck-suppress redundantAssignment
dest->used = 0; dest->used = 0; // cppcheck-suppress redundantAssignment
if (decode) { if (decode) {
JSAMPARRAY scanlines; JSAMPARRAY scanlines;

View File

@@ -41,7 +41,7 @@ static void _http_request_watcher(int fd, short event, void *v_server);
static void _http_refresher(int fd, short event, void *v_server); static void _http_refresher(int fd, short event, void *v_server);
static void _http_queue_send_stream(us_server_s *server, bool stream_updated, bool frame_updated); static void _http_queue_send_stream(us_server_s *server, bool stream_updated, bool frame_updated);
static bool _expose_frame(us_server_s *server, us_frame_s *frame); static bool _expose_frame(us_server_s *server, const us_frame_s *frame);
static const char *_http_get_header(struct evhttp_request *request, const char *key); static const char *_http_get_header(struct evhttp_request *request, const char *key);
static char *_http_get_client_hostport(struct evhttp_request *request); static char *_http_get_client_hostport(struct evhttp_request *request);
@@ -865,7 +865,7 @@ static void _http_refresher(int fd, short what, void *v_server) {
const int ri = us_ring_consumer_acquire(ring, 0); const int ri = us_ring_consumer_acquire(ring, 0);
if (ri >= 0) { if (ri >= 0) {
us_frame_s *const frame = ring->items[ri]; const us_frame_s *const frame = ring->items[ri];
frame_updated = _expose_frame(server, frame); frame_updated = _expose_frame(server, frame);
stream_updated = true; stream_updated = true;
us_ring_consumer_release(ring, ri); us_ring_consumer_release(ring, ri);
@@ -896,7 +896,7 @@ static void _http_refresher(int fd, short what, void *v_server) {
} }
} }
static bool _expose_frame(us_server_s *server, us_frame_s *frame) { static bool _expose_frame(us_server_s *server, const us_frame_s *frame) {
us_server_exposed_s *const ex = server->run->exposed; us_server_exposed_s *const ex = server->run->exposed;
US_LOG_DEBUG("HTTP: Updating exposed frame (online=%d) ...", frame->online); US_LOG_DEBUG("HTTP: Updating exposed frame (online=%d) ...", frame->online);