Permalink
Browse files

MDL-19718 fixed critical race condition when deleting posts - credit …

…goes to Ashley Holman; backported from MOODLE_19_STABLE
  • Loading branch information...
1 parent 094a030 commit a6bbcb9897717d1fba1d292057e6b70f2be05bd9 skodak committed Sep 27, 2009
Showing with 6 additions and 1 deletion.
  1. +6 −1 mod/forum/lib.php
View
7 mod/forum/lib.php
@@ -2784,7 +2784,12 @@ function forum_file_area_name($post) {
* TODO document
*/
function forum_file_area($post) {
- return make_upload_directory( forum_file_area_name($post) );
+ $path = forum_file_area_name($post);
+ if ($path) {
+ return make_upload_directory($path);
+ } else {
+ return false;
+ }
}
/**

0 comments on commit a6bbcb9

Please sign in to comment.