Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function mymodule_long_operation() {
- if (lock_acquire('mymodule_long_operation')) {
- // Do the long operation here.
- // ...
- lock_release('mymodule_long_operation');
- }
- }
- function mymodule_long_operation() {
- if (lock_acquire('mymodule_long_operation')) {
- // SOMETHING GOES WRONG HERE!
- lock_release('mymodule_long_operation');
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement