[geeklog-devel] Geeklog-Nightly fail to install

Tom websitemaster at cogeco.net
Tue Oct 8 19:11:36 EDT 2013


Thanks for the bug report. I have added it in
http://project.geeklog.net/tracking/view.php?id=1702

Let's see what Dirks says about you (and I am assuming other normal users)
not being able to add in a bug report for 2.1.0. I don't see why you
shouldn't be allowed to (or any version currently in development).

I will have to take a look at this bug. I haven't done a complete install in
a while and only upgrades recently.

Yeah $TEMPLATE_OPTIONS had to be coded that way to remain compatible. The
layout path probably hasn't been set or loaded yet hence the error so your
solution is probably the best one but I will run the install a few times
when I have time to check it out.

Tom
 

-----Original Message-----
From: geeklog-devel-bounces at lists.geeklog.net
[mailto:geeklog-devel-bounces at lists.geeklog.net] On Behalf Of Erwan HAMON
Sent: October-08-13 4:30 PM
To: geeklog-devel at lists.geeklog.net
Subject: [geeklog-devel] Geeklog-Nightly fail to install

Hi,

I've created myself an account on Mantis but cannot report bugs against
2.1.0 or nightly.

Here is a wicked bug and a patch.

Geeklog-Nightly Build #524 (Oct 1, 2013 8:02:22 AM) fails to install and
only leaves this message in the error.log:

Thu Oct  3 07:23:50 2013 - ::1 - 2 -
file_put_contents(instance__topic_tree__c81e728d9d4c2f636f067f89cc14862c.php
): failed to open stream: Permission denied @
/path/to/geeklog-nightly/system/classes/template.class.php line 2091 

It took me a while to find out it's because lib-common, hence
template.class.php, is included from within a function. 
$TEMPLATE_OPTIONS is initialised as a local variable within that function's
scope. The global $TEMPLATE_OPTIONS remains null.

Bellow is a patch that allows the install to get thru, but it might be
better to review $TEMPLATE_OPTIONS' initialisation or to forbid includes
from within a function:

--- /path/to/vanilla/geeklog-nightly/public_html/lib-common.php
2013-10-01 14:03:12.000000000 +0200
+++ /path/to/my/geeklog-nightly/public_html/lib-common.php     2013-10-08
19:01:01.652876627 +0200
@@ -527,7 +527,9 @@
     $_TOPICS = TOPIC_buildTree(TOPIC_ROOT, true);
 
     // Save updated topic tree and date
-    CACHE_create_instance($cacheInstance, serialize($_TOPICS), true);
+    if (isset($GLOBALS['TEMPLATE_OPTIONS']) && is_array($TEMPLATE_OPTIONS)
&& isset($TEMPLATE_OPTIONS['path_cache'])) {
+        CACHE_create_instance($cacheInstance, serialize($_TOPICS), true);
+    }
 } else {
     $_TOPICS = unserialize($serialized_topic_tree);
 }    



--
Erwan HAMON - http://hamon.erwan.free.fr/
_______________________________________________
geeklog-devel mailing list
geeklog-devel at lists.geeklog.net
http://eight.pairlist.net/mailman/listinfo/geeklog-devel




More information about the geeklog-devel mailing list