Lines Matching refs:vhd
68 struct per_vhost_data__minimal *vhd =
76 vhd = lws_protocol_vh_priv_zalloc(lws_get_vhost(wsi),
79 vhd->context = lws_get_context(wsi);
80 vhd->protocol = lws_get_protocol(wsi);
81 vhd->vhost = lws_get_vhost(wsi);
85 /* add ourselves to the list of live pss held in the vhd */
86 pss->pss_list = vhd->pss_list;
87 vhd->pss_list = pss;
89 pss->last = vhd->current;
95 ppss, vhd->pss_list) {
104 if (!vhd->amsg.payload)
107 if (pss->last == vhd->current)
111 m = lws_write(wsi, ((unsigned char *)vhd->amsg.payload) +
112 LWS_PRE, vhd->amsg.len, LWS_WRITE_TEXT);
113 if (m < (int)vhd->amsg.len) {
118 pss->last = vhd->current;
122 if (vhd->amsg.payload)
123 __minimal_destroy_message(&vhd->amsg);
125 vhd->amsg.len = len;
127 vhd->amsg.payload = malloc(LWS_PRE + len);
128 if (!vhd->amsg.payload) {
133 memcpy((char *)vhd->amsg.payload + LWS_PRE, in, len);
134 vhd->current++;
141 ppss, vhd->pss_list) {