Skip to content

Conversation

@tjni
Copy link

@tjni tjni commented Nov 3, 2024

Resolves #386:

uamqp/c_uamqp.c:87603:146: error: incompatible function pointer types passing 'void (void *, enum MESSAGE_RECEIVER_STATE_TAG, enum MESSAGE_RECEIVER_STATE_TAG)' to parameter of type 'ON_MESSAGE_RECEIVER_STATE_CHANGED' (aka 'void (*)(const void *, enum MESSAGE_RECEIVER_STATE_TAG, enum MESSAGE_RECEIVER_STATE_TAG)') [-Wincompatible-function-pointer-types]
  __pyx_t_1 = ((struct __pyx_vtabstruct_5uamqp_7c_uamqp_cMessageReceiver *)__pyx_v_receiver->__pyx_vtab)->create(__pyx_v_receiver, __pyx_v_link, __pyx_f_5uamqp_7c_uamqp_on_message_receiver_state_changed, ((void *)__pyx_v_callback_context)); if (unlikely(!__pyx_t_1)) __PYX_ERR(7, 23, __pyx_L1_error)

The issue seems to be that ON_MESSAGE_RECEIVER_STATE_CHANGED is defined as:

typedef void(*ON_MESSAGE_RECEIVER_STATE_CHANGED)(const void* context, MESSAGE_RECEIVER_STATE new_state, MESSAGE_RECEIVER_STATE previous_state);

where context is const void* and not void*. I'm not sure whether context really needs to be const since even in upstream code it's cast to something else and its state modified, but we already cast in this function so we can just adopt the same signature.

@tjni
Copy link
Author

tjni commented Dec 7, 2024

Hi @scbedd and @kashifkhan,

I understand that this package is deprecated, but is there possibility to merge this and release another patch version until this is formally archived? From the linked issue, it looks like it can resolve some pain.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[1.6.9] Failed building wheel for uamqp

1 participant