Skip to content

Commit

Permalink
Refine linkage for inline functions in drm.h (#3898)
Browse files Browse the repository at this point in the history
Removed static linkage on inline functions SbDrmSystemIsValid() and
SbDrmTicketIsValid().

Marking function as inline is enough to permit multiple definitions of
the function, and adding static will cause warnings in compile units
where the function is unused.

b/276483058
  • Loading branch information
xiaomings committed Jul 30, 2024
1 parent c43c951 commit be8e312
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions starboard/drm.h
Original file line number Diff line number Diff line change
Expand Up @@ -225,12 +225,12 @@ typedef void (*SbDrmServerCertificateUpdatedFunc)(SbDrmSystem drm_system,
// --- Functions -------------------------------------------------------------

// Indicates whether |drm_system| is a valid SbDrmSystem.
static SB_C_FORCE_INLINE bool SbDrmSystemIsValid(SbDrmSystem drm) {
SB_C_FORCE_INLINE bool SbDrmSystemIsValid(SbDrmSystem drm) {
return drm != kSbDrmSystemInvalid;
}

// Indicates whether |ticket| is a valid ticket.
static SB_C_FORCE_INLINE bool SbDrmTicketIsValid(int ticket) {
SB_C_FORCE_INLINE bool SbDrmTicketIsValid(int ticket) {
return ticket != kSbDrmTicketInvalid;
}

Expand Down

0 comments on commit be8e312

Please sign in to comment.