/* This function is used to build a response to a message processed by calling wps_process_msg(). The caller is responsible for freeing the buffer.  */
struct wpabuf* wps_get_msg(struct wps_data *wps, enum wsc_op_code *op_code)
/* This function is used to build a response to a message processed by calling wps_process_msg(). The caller is responsible for freeing the buffer.  */
struct wpabuf* wps_get_msg(struct wps_data *wps, enum wsc_op_code *op_code)
{
    if (wps->registrar)
        return wps_registrar_get_msg(wps, op_code);
    else
        return wps_enrollee_get_msg(wps, op_code);
}