apps/tv: Fix -Werror=class-memaccess
Fix -Werror=class-memaccess, pointed by gcc8. * Remove unneed memset() at line 300, since constructor of media_format already runs memset(). * Replace other memset() with media_format.Clear(). * Remove trailing tabs. Change-Id: I3207842603208b33a77cfd88de7a8a0e52fb2d72 Reviewed-on: https://review.haiku-os.org/c/1116 Reviewed-by: waddlesplash <[email protected]>
This commit is contained in:
committed by
waddlesplash
parent
752ec5c625
commit
74d9e19df9
@@ -297,7 +297,6 @@ Controller::ConnectNodes()
|
||||
if (count < 1)
|
||||
HandleError("No free audio input", -1);
|
||||
|
||||
memset(&fmt, 0, sizeof(fmt));
|
||||
err = gMediaRoster->Connect(output.source, input.destination, &fmt, &audio_output, &audio_input);
|
||||
HandleError("Can't connect audio", err);
|
||||
|
||||
@@ -322,7 +321,7 @@ Controller::ConnectNodes()
|
||||
fVideoNode->SetOverlayEnabled(true);
|
||||
for (int i = 0; cspaces_overlay[i] != B_NO_COLOR_SPACE; i++) {
|
||||
printf("trying connect with colorspace 0x%08x\n", cspaces_overlay[i]);
|
||||
memset(&fmt, 0, sizeof(fmt));
|
||||
fmt.Clear();
|
||||
fmt.type = B_MEDIA_RAW_VIDEO;
|
||||
fmt.u.raw_video.display.format = cspaces_overlay[i];
|
||||
err = gMediaRoster->Connect(output.source, input.destination, &fmt, &video_output, &video_input);
|
||||
@@ -334,7 +333,7 @@ Controller::ConnectNodes()
|
||||
fVideoNode->SetOverlayEnabled(false);
|
||||
for (int i = 0; cspaces_bitmap[i] != B_NO_COLOR_SPACE; i++) {
|
||||
printf("trying connect with colorspace 0x%08x\n", cspaces_bitmap[i]);
|
||||
memset(&fmt, 0, sizeof(fmt));
|
||||
fmt.Clear();
|
||||
fmt.type = B_MEDIA_RAW_VIDEO;
|
||||
fmt.u.raw_video.display.format = cspaces_bitmap[i];
|
||||
err = gMediaRoster->Connect(output.source, input.destination, &fmt, &video_output, &video_input);
|
||||
|
||||
Reference in New Issue
Block a user