Differences

This shows you the differences between two versions of the page.

Link to this comparison view

app:laboratoare:04 [2025/11/12 05:02]
alexandru.bala [Variabile condiție]
app:laboratoare:04 [2025/11/12 05:03] (current)
alexandru.bala [Variabile condiție]
Line 360: Line 360:
  
     pthread_mutex_init (&​mutex,​ NULL);     pthread_mutex_init (&​mutex,​ NULL);
- 
     sem_init (&​full_sem,​ 0, 0);     sem_init (&​full_sem,​ 0, 0);
     sem_init (&​empty_sem,​ 0, 3);     sem_init (&​empty_sem,​ 0, 3);
Line 380: Line 379:
     sem_destroy (&​empty_sem);​     sem_destroy (&​empty_sem);​
     sem_destroy (&​full_sem);​     sem_destroy (&​full_sem);​
- 
     pthread_mutex_destroy (&​mutex);​     pthread_mutex_destroy (&​mutex);​
  
Line 495: Line 493:
  }  }
  
-        ​pthread_cond_init ​(&​empty_cond,​ NULL); +        ​pthread_cond_destroy ​(&​empty_cond,​ NULL); 
- pthread_cond_init ​(&​full_cond,​ NULL);+ pthread_cond_destroy ​(&​full_cond,​ NULL);
  pthread_mutex_destroy(&​mutex);​  pthread_mutex_destroy(&​mutex);​
  
app/laboratoare/04.1762916521.txt.gz · Last modified: 2025/11/12 05:02 by alexandru.bala
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0