Forum: CFEngine Help
Subject: Re: multidimensional array usage
Author: lauwersw
Link to topic: https://cfengine.com/forum/read.php?3,23753,24069#msg-24069
Hi,
I think I have found a variant of this bug. Using this code:
bundle agent level1
{
methods:
any::
"a" usebundle => level2("passwd"
Forum: CFEngine Help
Subject: Re: multidimensional array usage
Author: victor
Link to topic: https://cfengine.com/forum/read.php?3,23753,23768#msg-23768
Thanks a lot Diego and Mark.
I've reported the bug as https://cfengine.com/bugtracker/view.php?id=837
Regards.
___
On 10/18/2011 11:17 AM, Mikhail Gusarov wrote:
> There's open bug about it: https://cfengine.com/bugtracker/view.php?id=397
Oh, wait, this bug is inverse one -- expression isn't evaluated
correctly if there are braces around it :)
--
Mikhail Gusarov
Software Engineer
CFEngine AS
Nydalsveien 3
On 10/18/2011 11:15 AM, no-re...@cfengine.com wrote:
> This seems to be a quirk of the evaluation, if I add braces around the list
> function:
<...>
> You should report this as a bug.
There's open bug about it: https://cfengine.com/bugtracker/view.php?id=397
--
Mikhail Gusarov
Software Engi
Forum: CFEngine Help
Subject: Re: multidimensional array usage
Author: mark
Link to topic: https://cfengine.com/forum/read.php?3,23753,23765#msg-23765
This seems to be a quirk of the evaluation, if I add braces around the list
function:
body common control
{
bundlesequence => { "parse_array"
Forum: CFEngine Help
Subject: Re: multidimensional array usage
Author: zzamboni
Link to topic: https://cfengine.com/forum/read.php?3,23753,23761#msg-23761
I have to say I am stumped. I think this may be a bug. Any core developers who
want to pitch in on this?
Here's the standalone example:
body
Forum: CFEngine Help
Subject: Re: multidimensional array usage
Author: victor
Link to topic: https://cfengine.com/forum/read.php?3,23753,23756#msg-23756
Hello Diego,
Thanks a lot for your fast reply. I'm not sure if i'm doing something wrong,
but it doesn't work:
bundle agent parse_array
{
Forum: CFEngine Help
Subject: Re: multidimensional array usage
Author: zzamboni
Link to topic: https://cfengine.com/forum/read.php?3,23753,23755#msg-23755
You could get them through an intermediate array built using implicit looping.
Something like this (untested):
"hostnames" slist => getindi