Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F168589205
D11150.id29474.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
779 B
Referenced Files
None
Subscribers
None
D11150.id29474.diff
View Options
Index: usr.sbin/bhyve/rfb.c
===================================================================
--- usr.sbin/bhyve/rfb.c
+++ usr.sbin/bhyve/rfb.c
@@ -765,7 +765,8 @@
int i;
#endif
- pthread_t tid;
+ pthread_t tid = 0;
+ int error = 0;
uint32_t sres;
int len;
@@ -877,8 +878,9 @@
rfb_send_screen(rc, cfd, 1);
- pthread_create(&tid, NULL, rfb_wr_thr, rc);
- pthread_set_name_np(tid, "rfbout");
+ error = pthread_create(&tid, NULL, rfb_wr_thr, rc);
+ if (error == 0)
+ pthread_set_name_np(tid, "rfbout");
/* Now read in client requests. 1st byte identifies type */
for (;;) {
@@ -914,7 +916,8 @@
}
done:
rc->cfd = -1;
- pthread_join(tid, NULL);
+ if (error == 0)
+ pthread_join(tid, NULL);
if (rc->enc_zlib_ok)
deflateEnd(&rc->zstream);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Aug 30, 4:07 AM (2 h, 58 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
37565966
Default Alt Text
D11150.id29474.diff (779 B)
Attached To
Mode
D11150: Initialize pthread_t: CID 1375950
Attached
Detach File
Event Timeline
Log In to Comment