You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by GitBox <gi...@apache.org> on 2019/06/25 16:39:25 UTC

[GitHub] [mynewt-core] mlaz commented on a change in pull request #1897: os_sem: Preventing token overflow.

mlaz commented on a change in pull request #1897: os_sem: Preventing token overflow.
URL: https://github.com/apache/mynewt-core/pull/1897#discussion_r297285370
 
 

 ##########
 File path: kernel/os/src/os_sem.c
 ##########
 @@ -42,6 +42,7 @@ os_sem_init(struct os_sem *sem, uint16_t tokens)
         goto done;
     }
 
+    sem->max_tokens = tokens;
 
 Review comment:
   @andrzej-kaczmarek agreed, but wouldn't the problem also be to pass the initial value? probably more likely to happen then to OF an uint16_t. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services