Skip to content

Commit

Permalink
send env variable in confconn, so we know if we are on FF or chrome
Browse files Browse the repository at this point in the history
  • Loading branch information
z-dule committed Jan 30, 2025
1 parent 955b932 commit 20bdeee
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions include/avs_econn.h
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ struct econn_message {
struct zapi_ice_server *turnv;
size_t turnc;
bool update;
int env;
char *tool;
char *toolver;
enum econn_confconn_status status;
Expand Down
2 changes: 2 additions & 0 deletions src/ccall/ccall.c
Original file line number Diff line number Diff line change
Expand Up @@ -2167,6 +2167,8 @@ static int ccall_send_conf_conn(struct ccall *ccall,
if (err) {
goto out;
}
msg->u.confconn.env = msystem_get_env();

msg->u.confconn.update = update;
msg->u.confconn.selective_audio = true;
msg->u.confconn.selective_video = true;
Expand Down
4 changes: 4 additions & 0 deletions src/econn_fmt/msg.c
Original file line number Diff line number Diff line change
Expand Up @@ -662,6 +662,8 @@ int econn_message_encode(char **strp, const struct econn_message *msg)
"%s", msg->u.confconn.tool);
jzon_add_str(jobj, "toolver",
"%s", msg->u.confconn.toolver);
jzon_add_int(jobj, "env",
msg->u.confconn.env);
jzon_add_int(jobj, "status",
msg->u.confconn.status);
jzon_add_bool(jobj, "selective_audio",
Expand Down Expand Up @@ -1122,6 +1124,8 @@ int econn_message_decode(struct econn_message **msgp,
goto out;
}

jzon_int(&msg->u.confconn.env, jobj, "env");

/* status is optional, missing = 0 */
err = jzon_int(&status, jobj, "status");
if (err) {
Expand Down

0 comments on commit 20bdeee

Please sign in to comment.