| OLD | NEW |
| 1 /* | 1 /* |
| 2 * libusb synchronization using POSIX Threads | 2 * libusb synchronization using POSIX Threads |
| 3 * | 3 * |
| 4 * Copyright (C) 2011 Vitali Lovich <vlovich@aliph.com> | 4 * Copyright (C) 2011 Vitali Lovich <vlovich@aliph.com> |
| 5 * Copyright (C) 2011 Peter Stuge <peter@stuge.se> | 5 * Copyright (C) 2011 Peter Stuge <peter@stuge.se> |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Lesser General Public | 8 * modify it under the terms of the GNU Lesser General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2.1 of the License, or (at your option) any later version. | 10 * version 2.1 of the License, or (at your option) any later version. |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 goto finish; | 46 goto finish; |
| 47 | 47 |
| 48 err = pthread_mutex_init(mutex, attr); | 48 err = pthread_mutex_init(mutex, attr); |
| 49 | 49 |
| 50 finish: | 50 finish: |
| 51 if (attr == &stack_attr) | 51 if (attr == &stack_attr) |
| 52 pthread_mutexattr_destroy(&stack_attr); | 52 pthread_mutexattr_destroy(&stack_attr); |
| 53 | 53 |
| 54 return err; | 54 return err; |
| 55 } | 55 } |
| OLD | NEW |