6.0.0-beta1
7/5/25

[#6048] cannot add ACLs to kolab's default tasklist "Aufgaben" (German)
Summary cannot add ACLs to kolab's default tasklist "Aufgaben" (German)
Queue Kolab
Type Bug
State Resolved
Priority 2. Medium
Owners wrobel (at) horde (dot) org
Requester m.gabriel (at) das-netzwerkteam (dot) de
Created 12/25/2007 (6402 days ago)
Due
Updated 04/25/2008 (6280 days ago)
Assigned 04/25/2008 (6280 days ago)
Resolved 04/25/2008 (6280 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
04/25/2008 06:58:15 AM Gunnar Wrobel Comment #18
State ⇒ Resolved
Reply to this comment
Fixed in CVS. Please retest with caching enabled and reopen if the 
problem persists.
04/25/2008 04:31:28 AM Gunnar Wrobel State ⇒ Assigned
 
04/24/2008 10:32:23 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #17 Reply to this comment
hi gunnar,
Hi Mike,

the location of the error does indicate that your Share/kolab.php
file does not seem to match Horde CVS. Are there any additional
patches applied? If you use the current Share/kolab.php from
FRAMEWORK_3 you should have the getACL call on line 1236.
i use your external-horde-cvs.sh



and: yes, indeed, i have the distlist patch in the Share/kolab.php.   
the corresponding location is line 1236 in vanilla FRAMEWORK_3.
If you deactivate share caching, does the problem persist?
ahh... ok... it works when caching is disabled...



mike
04/24/2008 04:06:38 PM Gunnar Wrobel Comment #16
State ⇒ Feedback
Reply to this comment
Hi Mike,



the location of the error does indicate that your Share/kolab.php file 
does not seem to match Horde CVS. Are there any additional patches 
applied? If you use the current Share/kolab.php from FRAMEWORK_3 you 
should have the getACL call on line 1236.



If you deactivate share caching, does the problem persist?
04/01/2008 03:25:23 PM Chuck Hagenbuch State ⇒ Assigned
 
04/01/2008 10:10:49 AM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #15 Reply to this comment
hi gunnar,



here is a var_dump of the object that causes the error (_imap points 
to NULL!?!?)... is the ImapFolder_Permission constructor call faulty?



object(ImapFolder_Permission)#23 (7) { ["_folder"]=>  string(23) 
"INBOX/Aufgaben (AIKIDO)" ["_imap"]=>  &NULL ["data"]=>  array(1) { 
["users"]=>  array(2) { ["m.gabriel@das-netzwerkteam.de"]=>  int(30) 
["c.music@das-netzwerkteam.de"]=>  int(6) } } ["_owner"]=>  string(29) 
"m.gabriel@das-netzwerkteam.de" ["datatree"]=>  NULL ["name"]=>  NULL 
["order"]=>  NULL }



Fatal error: Call to a member function getACL() on a non-object in 
/usr/local/share/_horde-versions_/horde3-kolab-cvs/horde/lib/Horde/Share/kolab.php on line 
1452



best,

mike
04/01/2008 09:58:06 AM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #14 Reply to this comment
however, the php error is slightly different now:



<quote>

Fatal error: Call to a member function getACL() on a non-object in 
/usr/local/share/_horde-versions_/horde3-kolab-cvs/horde/lib/Horde/Share/kolab.php on line 
1451

</quote>
04/01/2008 09:56:46 AM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #13 Reply to this comment
hi gunnar,
Has this been fixed with the recent changes in CVS? From the error
report I assume it is the same kind of problems since the arrays were
messed up in the Kolab driver. Closing for now, please reopen if the
problem persists.
no, the problem remains... in only remembered this request today and 
tested it...



mike
03/03/2008 08:06:49 AM Gunnar Wrobel Comment #12
State ⇒ Resolved
Reply to this comment
Has this been fixed with the recent changes in CVS? From the error 
report I assume it is the same kind of problems since the arrays were 
messed up in the Kolab driver. Closing for now, please reopen if the 
problem persists.
01/16/2008 10:50:01 PM Jan Schneider Assigned to Gunnar Wrobel
State ⇒ Assigned
 
12/28/2007 07:37:21 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #11 Reply to this comment
sorry for the delay. yes, i looked at it again toroughly. it is so!
12/26/2007 05:49:24 PM Chuck Hagenbuch Comment #10 Reply to this comment
the bug occured already without php5-suhosin extension installed. now
that it is installed, there is no change...
So you have uninstalled suhosin, restarted Apache, verified that 
suhosin is gone from the phpinfo page, re-tested, and still have the 
issue?
12/26/2007 05:28:08 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #9 Reply to this comment
It depends on how your PHP package is built - if it's statically
compiled you need a different PHP build.
suhosin is loaded as an extension. the phpinfo page claims that 
suhosin is comiled into php5, but you can only configure it, when the 
suhosin.so extension is loaded...



the bug occured already without php5-suhosin extension installed. now 
that it is installed, there is no change...



hmmm...
12/26/2007 05:02:37 PM Chuck Hagenbuch Comment #8 Reply to this comment
It depends on how your PHP package is built - if it's statically 
compiled you need a different PHP build.
12/26/2007 05:00:54 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #7 Reply to this comment
Can you try turning off suhosin? It's been the weak link in a lot of
broken PHP behavior we've seen.
not sure how to do this. php.ini? or do i have to install a php5 with 
suhosin diabled (i.e. compile from source)? could not find any hints 
to that with google search...




12/26/2007 03:47:38 PM Chuck Hagenbuch Comment #6 Reply to this comment
BTW: where is the _shareMap stored? datatree, php session, filesystem?
It's just an array, it's not stored anywhere except for in memory 
during a single page request. It helps prevent duplicate fetching of a 
single share during one page load.



Can you try turning off suhosin? It's been the weak link in a lot of 
broken PHP behavior we've seen.
12/26/2007 03:42:35 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #5 Reply to this comment
i have played around with it a little more.



i have replaced the original method in lib/Horde/Share.php:



     function &getShareById($cid)

     {

         if (!isset($this->_shareMap[$cid])) {

             $share = &$this->_getShareById($cid);

             if (is_a($share, 'PEAR_Error')) {

                 return $share;

             }

             $share->setShareOb($this);

             $name = $share->getName();

             $this->_cache[$name] = &$share;

             $this->_shareMap[$cid] = $name;

         }

         return $this->_cache[$this->_shareMap[$cid]];

     }



by my own debug version (what it does: do not use _cache, but update _cache):



     function &getShareById($cid)

     {

           $share = &$this->_getShareById($cid);

           if (is_a($share, 'PEAR_Error')) {

               return $share;

           }

           $share->setShareOb($this);

           $name = $share->getName();

           $this->_cache[$name] = &$share;

           $this->_shareMap[$cid] = $name;

           return $share

     }



this debug method raises the same error...



BUT!!! if i comment out one line in my this debug method, it suddenly 
works (although on the first spot this does not make sense...):



     function &getShareById($cid)

     {

           $share = &$this->_getShareById($cid);

           if (is_a($share, 'PEAR_Error')) {

               return $share;

           }

           $share->setShareOb($this);

           $name = $share->getName();

           $this->_cache[$name] = &$share;

          /*

           * $this->_shareMap[$cid] = $name;

           */

           return $share

     }



and the return value of the original getShareById() method is exactly 
what is stored in $this->_shareMap[$cid] ("INBOX/Aufgaben", 
"INBOX/Aufgaben (PRIVAT)", etc. i.e. the corresponding share name).



is it possible that $this->_cache[$name] and $this->_shareMap[$cid] 
refer to the same data structure????



weird things going on in php...



BTW: where is the _shareMap stored? datatree, php session, filesystem?



hope this helps...

mike
12/26/2007 02:25:09 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #4 Reply to this comment
What PHP version are you using?
php-5.4.2-2 as currently in debian unstable
What is $share
when it's assigned there
INBOX/Aufgaben (already added this as a comment... sorry for the redundancy)
and then later on the error, what is it
both with and without the reference?
what exactly do you mean by this? can you give a clue on where to put 
my debug prints and var_dumps?



mike






12/26/2007 02:21:29 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #3 Reply to this comment
the return value of Horde_Share::&getShareById() as in 
horde-webmail-1.1rc1 returns a string: "INBOX/Aufgaben" (which is the 
kolab user default task folder in Germain).




12/26/2007 04:25:00 AM Chuck Hagenbuch Comment #2
State ⇒ Feedback
Reply to this comment
What you are doing there is breaking object references - which almost 
certainly is not the fix; we need to find out why doing that fixes 
things in your case. What PHP version are you using? What is $share 
when it's assigned there, and then later on the error, what is it both 
with and without the reference?
12/25/2007 11:59:55 PM m (dot) gabriel (at) das-netzwerkteam (dot) de Comment #1
Priority ⇒ 2. Medium
State ⇒ Unconfirmed
New Attachment: share.patch Download
Queue ⇒ Kolab
Type ⇒ Bug
Summary ⇒ cannot add ACLs to kolab's default tasklist "Aufgaben" (German)
Reply to this comment
i am using kolab-2.1 and horde-webmail-1.1rc1



i cannot add ACLs to kolab's default tasklist "Aufgaben" (German), the 
php error says:



Fatal error: Call to a member function get() on a non-object in 
/usr/local/share/_horde-versions_/horde-webmail-1.1-rc1-netzwerkteam/services/shares/edit.php on line 
67



i have tracked the issue down to lib/Horde/Share.php and with kolab my 
fix now works fine, not sure about other backends...



diff -ur horde-webmail-1.1-rc1/lib/Horde/Share.php 
horde-webmail-1.1-rc1-netzwerkteam/lib/Horde/Share.php

--- horde-webmail-1.1-rc1/lib/Horde/Share.php   2007-11-29 
12:32:53.000000000 +0000

+++ horde-webmail-1.1-rc1-netzwerkteam/lib/Horde/Share.php       
2007-12-25 23:57:02.000000000 +0000

@@ -212,7 +212,7 @@

              }

              $share->setShareOb($this);

              $name = $share->getName();

-            $this->_cache[$name] = &$share;

+            $this->_cache[$name] = $share;

              $this->_shareMap[$cid] = $name;

          }




Saved Queries