Skip to content

Commit

Permalink
Correctly use enum fy_composer_process_event for event processing
Browse files Browse the repository at this point in the history
Enums may be interchangeable with ints, but newer compilers throw
warnings now.

Signed-off-by: Pantelis Antoniou <[email protected]>
  • Loading branch information
pantoniou committed Sep 27, 2024
1 parent 592ccc1 commit 2cf9f45
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/lib/fy-composer.c
Original file line number Diff line number Diff line change
Expand Up @@ -363,14 +363,14 @@ fy_composer_process_event(struct fy_composer *fyc, struct fy_event *fye)
int rc;

if (!fyc || !fye)
return -1;
return FYCR_ERROR;

/* start at the head */
fypp = fy_path_list_head(&fyc->paths);

/* no top? something's very out of order */
if (!fypp)
return -1;
return FYCR_ERROR;

rc = fy_composer_process_event_private(fyc, fye, fypp);

Expand Down
2 changes: 1 addition & 1 deletion src/lib/fy-composer.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ struct fy_composer {

struct fy_composer *fy_composer_create(struct fy_composer_cfg *cfg);
void fy_composer_destroy(struct fy_composer *fyc);
int fy_composer_process_event(struct fy_composer *fyc, struct fy_event *fye);
enum fy_composer_return fy_composer_process_event(struct fy_composer *fyc, struct fy_event *fye);

struct fy_composer_cfg *fy_composer_get_cfg(struct fy_composer *fyc);
void *fy_composer_get_cfg_userdata(struct fy_composer *fyc);
Expand Down

0 comments on commit 2cf9f45

Please sign in to comment.