Skip to content

bug: master macOS build is red after #2865 — two conversion diagnostics the Linux replay missed #2869

Closed

Description

@zackees

What

The nightly Scheduled run on master (40825610950, head 5c3a91bb7 = the merge of #2865) fails the two macOS compile jobs with conversion diagnostics that #2865 did not cover:

job annotation
Build 🧱 / macOS 🍏 (x86_64) plugins/obs-ffmpeg/obs-ffmpeg-rist.h:175: implicit conversion changes signedness: int to enum rist_profile [-Werror,-Wsign-conversion]
Analyze 🔬 / macOS 🍏 (clang-analyze) plugins/obs-ffmpeg/obs-ffmpeg-rist.h:175, plus plugins/obs-ffmpeg/obs-ffmpeg-source.c.h:437: implicit conversion loses integer precision: long long to enum video_range_type [-Wshorten-64-to-32]

CEF Chromium Support 🌐 is also red in that run but is by design (#1864).

Why #2865 missed them

#2865 turned on -Wconversion;-Wsign-conversion;-Wfloat-conversion for the obs-ffmpeg target and fixed the 109 diagnostics its RED commit reported. Those came from a Linux replay of the target's unity TUs: the Linux Tier 2 tree does not configure ENABLE_FRONTEND=OFF plugin targets, and the replay compiles with GCC flag defaults and Linux headers, so neither the librist enum parameter nor clang's -Wshorten-64-to-32 on obs_data_get_int() (a long long) appears there. macOS builds the target with Xcode/clang and CMAKE_COMPILE_WARNING_AS_ERROR, so both are hard errors on master.

Fix

Two explicit casts at the call boundaries, no behaviour change (each keeps the value the code already computed):

  • obs-ffmpeg-rist.h:175: RISTContext::profile is an int field holding RIST_PROFILE_MAIN; pass it as (enum rist_profile)s->profile to rist_sender_create().
  • obs-ffmpeg-source.c.h:437: range is an enum video_range_type, assigned from obs_data_get_int() (a long long); (enum video_range_type)obs_data_get_int(...).

RED evidence is the nightly annotations above (real compiler output at the head that introduced the regression). GREEN evidence is the macOS x86_64 / clang-analyze lane compiling the target with the three groups still on.

Acceptance

  • Build 🧱 / macOS 🍏 (x86_64) and Analyze 🔬 / macOS 🍏 compile obs-ffmpeg at the head with -Wconversion -Wsign-conversion -Wfloat-conversion and -Werror.
  • No -Wno-* pin returns; the casts keep the values.
  • Next nightly Scheduled run on master is not red in those two jobs (CEF excluded).

Activity

  1. added
    infra
    P0
    size:S
    on Oct 29, 2026
  2. zackees commented on Oct 29, 2026

    @zackees
    MemberAuthor

    Claiming: #2869 — the two macOS conversion diagnostics #2865 missed.

    1. RED: already real compiler output — nightly run 40825610950 at head 5c3a91bb7 fails Build 🧱 / macOS 🍏 (x86_64) and Analyze 🔬 / macOS 🍏 (clang-analyze) on obs-ffmpeg-rist.h:175 and obs-ffmpeg-source.c.h:437.
    2. GREEN: explicit casts only ((enum rist_profile)s->profile, (enum video_range_type)obs_data_get_int(...)), no -Wno-* back, one PR that closes this issue.
    3. Evidence: dispatch the macOS build lane on the branch so the target compiles with the three conversion groups on and -Werror; the next nightly confirms on master.

    First PR within the tick.

  3. zackees commented on Oct 29, 2026

    @zackees
    MemberAuthor

    /ready

    Triage: P0 master red. Two conversion diagnostics in obs-ffmpeg that #2865's Linux replay could not see (plugin target not built in Tier 2, clang-only diagnostics). Fix is two explicit casts, one PR closing this issue.

  4. zackees commented on Oct 29, 2026

    @zackees
    MemberAuthor

    Fix up: PR #2870 (branch fix/2869-macos-conversions), two explicit casts and no -Wno-* back. macOS evidence: Scheduled 40827510045 dispatched on the branch (PR CI never selects the macOS lanes for a plugins/obs-ffmpeg change). The PR is queued once those jobs are green, per the comment on #2870.

  5. added
    ready
    on Oct 29, 2026
  6. added 2 commits that reference this issue on Oct 30, 2026
    bc8b13c
    05835cb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P0infrareadysize:S

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions