Subj : New Defects reported by Coverity Scan for Synchronet To : cov-scan@synchro.net From : scan-admin@coverity.com Date : Mon Apr 24 2023 12:38:45 Hi, Please find the latest report on new defect(s) introduced to Synchronet found with Coverity Scan. 7 new defect(s) introduced to Synchronet found with Coverity Scan. 2 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent build analyzed by Coverity Scan. New defect(s) Reported-by: Coverity Scan Showing 7 of 7 defect(s) ** CID 452578: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 288 in bitmap_vmem_puttext_locked() ________________________________________________________________________________________________________ *** CID 452578: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 288 in bitmap_vmem_puttext_locked() 282 for(x=sx-1;xvmem[y*cio_textinfo.screenwidth+x], fill++, sizeof(*fill)); 284 bitmap_draw_one_char(x+1, y+1); 285 } 286 } 287 pthread_mutex_lock(&vstatlock); >>> CID 452578: Concurrent data access violations (ATOMICITY) >>> Using an unreliable value of "vmem_ptr" inside the second locked section. If the data that "vmem_ptr" depends on was changed by another thread, this use might be incorrect. 288 release_vmem(vmem_ptr); 289 pthread_mutex_unlock(&vstatlock); 290 return(1); 291 } 292 293 static void ** CID 452577: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 850 in update_from_vmem() ________________________________________________________________________________________________________ *** CID 452577: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 850 in update_from_vmem() 844 bitmap_draw_one_char(x+1,y+1); 845 } 846 pos++; 847 } 848 } 849 pthread_mutex_lock(&vstatlock); >>> CID 452577: Concurrent data access violations (ATOMICITY) >>> Using an unreliable value of "vmem_ptr" inside the second locked section. If the data that "vmem_ptr" depends on was changed by another thread, this use might be incorrect. 850 release_vmem(vmem_ptr); 851 pthread_mutex_unlock(&vstatlock); 852 853 vs = vstat; 854 855 return(0); ** CID 452576: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 1239 in bitmap_movetext() ________________________________________________________________________________________________________ *** CID 452576: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 1239 in bitmap_movetext() 1233 } 1234 1235 bitmap_movetext_screen(&screena, x, y, tox, toy, direction, height, width); 1236 bitmap_movetext_screen(&screenb, x, y, tox, toy, direction, height, width); 1237 1238 pthread_mutex_lock(&vstatlock); >>> CID 452576: Concurrent data access violations (ATOMICITY) >>> Using an unreliable value of "vmem_ptr" inside the second locked section. If the data that "vmem_ptr" depends on was changed by another thread, this use might be incorrect. 1239 release_vmem(vmem_ptr); 1240 pthread_mutex_unlock(&vstatlock); 1241 pthread_mutex_unlock(&blinker_lock); 1242 1243 return(1); 1244 } ** CID 452575: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 1264 in bitmap_clreol() ________________________________________________________________________________________________________ *** CID 452575: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 1264 in bitmap_clreol() 1258 pthread_mutex_unlock(&vstatlock); 1259 for(x=cio_textinfo.curx+cio_textinfo.winleft-2; x>> CID 452575: Concurrent data access violations (ATOMICITY) >>> Using an unreliable value of "vmem_ptr" inside the second locked section. If the data that "vmem_ptr" depends on was changed by another thread, this use might be incorrect. 1264 release_vmem(vmem_ptr); 1265 pthread_mutex_unlock(&vstatlock); 1266 pthread_mutex_unlock(&blinker_lock); 1267 } 1268 1269 void bitmap_clrscr(void) ** CID 452574: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 1289 in bitmap_clrscr() ________________________________________________________________________________________________________ *** CID 452574: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 1289 in bitmap_clrscr() 1283 for(x=cio_textinfo.winleft-1; x>> CID 452574: Concurrent data access violations (ATOMICITY) >>> Using an unreliable value of "vmem_ptr" inside the second locked section. If the data that "vmem_ptr" depends on was changed by another thread, this use might be incorrect. 1289 release_vmem(vmem_ptr); 1290 pthread_mutex_unlock(&vstatlock); 1291 pthread_mutex_unlock(&blinker_lock); 1292 } 1293 1294 void bitmap_getcustomcursor(int *s, int *e, int *r, int *b, int *v) ** CID 452573: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 882 in bitmap_puttext() ________________________________________________________________________________________________________ *** CID 452573: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 882 in bitmap_puttext() 876 for(x=sx-1;x>> CID 452573: Concurrent data access violations (ATOMICITY) >>> Using an unreliable value of "vmem_ptr" inside the second locked section. If the data that "vmem_ptr" depends on was changed by another thread, this use might be incorrect. 882 release_vmem(vmem_ptr); 883 pthread_mutex_unlock(&vstatlock); 884 pthread_mutex_unlock(&blinker_lock); 885 return ret; 886 } 887 ** CID 452572: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 931 in bitmap_vmem_gettext() ________________________________________________________________________________________________________ *** CID 452572: Concurrent data access violations (ATOMICITY) /tmp/sbbs-Apr-24-2023/src/conio/bitmap_con.c: 931 in bitmap_vmem_gettext() 925 pthread_mutex_unlock(&vstatlock); 926 for(y=sy-1;yvmem[y*cio_textinfo.screenwidth+x], sizeof(*fill)); 929 } 930 pthread_mutex_lock(&vstatlock); >>> CID 452572: Concurrent data access violations (ATOMICITY) >>> Using an unreliable value of "vmem_ptr" inside the second locked section. If the data that "vmem_ptr" depends on was changed by another thread, this use might be incorrect. 931 release_vmem(vmem_ptr); 932 pthread_mutex_unlock(&vstatlock); 933 pthread_mutex_unlock(&blinker_lock); 934 return(1); 935 } 936 ________________________________________________________________________________________________________ To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=HRESupC-2F2Czv4BOaCWWCy7my0P0qcxCbhZ31OYv50yp-2FP9gGRhvFklLaQKuBylUrkMFB3WMR2p7qIYKYTZrh4BbWTBf-2B-2Fi5ZUVF-2Fo-2B6flxo-3Dr6L5_g4j7BHlu96plUOfCQsO0yRjoWZCZl8YGnZ-2FUtT39hrCXbrQFMtiQ7qKe-2BTRon-2FCE8v1liTsiFwBEYDEbQeWWd5eZFVeKpMGKUHmhD6LW8krne8DUx7vgGCgrnLZMbGKkkWrW3z-2FgyVLPDteaRWQpPZNj5xcazMwdijg8SS9WNZMtlsLir5gcOguFdBqjgvNYLOs-2BIw-2BtaMoNy3gAeALwzA-3D-3D --- SBBSecho 3.20-Linux * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705) .