From f05063fedf731cacf055f64f3ce1c1e253e2db07 Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Sat, 5 May 2012 17:02:22 +1200 Subject: [PATCH] When logging failed anonymous access, don't crash and burn. --- htdocs/public.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/htdocs/public.php b/htdocs/public.php index e5c619ca..cc12f8ee 100644 --- a/htdocs/public.php +++ b/htdocs/public.php @@ -24,7 +24,11 @@ if ( ! $request->IsPublic() && || $request->ticket->expired || ! $request->ticket->MatchesPath($request->path) ) ) { dbg_error_log( "caldav", 'Public: %d, Ticket: %d, Expired: %d, Matches(%s): %d', - $request->IsPublic(), isset($request->ticket), $request->ticket->expired, $request->path, $request->ticket->MatchesPath($request->path) + $request->IsPublic(), + isset($request->ticket), + (isset($request->ticket)?$request->ticket->expired:'--'), + $request->path, + (isset($request->ticket)?$request->ticket->MatchesPath($request->path):'--') ); $request->DoResponse( 403, translate('Anonymous users may only access public calendars') ); } -- 2.11.4.GIT