Bug in function gzip...

Ben Abbott bpabbott at mac.com
Sat Jan 5 11:35:14 CST 2008


On Jan 6, 2008, at 1:08 AM, Thomas Weber wrote:

> Am Samstag, den 05.01.2008, 17:18 +0100 schrieb Thomas Treichl:
>> Hi,
>>
>> I found a bug in the function gzip - to make sure that it isn't a  
>> Mac-only
>> problem I also tested the current CVS snapshot 3.0.0+ on my virtual  
>> Linux box
>> too. The bug isn't there in Octave 3.0.0.
>>
>> However, I don't have a fix for it, sorry, because I actually can't  
>> find out
>> what the problem here is. Can somebody help here please? This is my  
>> output:
>>
>>   octave:1> gzip ("~/.octaverc")
>>   error: invalid number of output arguments for expression X = RHS
>>   error: called from `?unknown?'
>>   error: cellfun: too many output arguments
>>   error: called from `myfileparts' in file
>
> What's "myfileparts"?
>
> 	Thomas

It's a function in gzip.m .

/.../octave/3.0.0/m/miscellaneous/gzip.m

<snip>
         [d, f] = myfileparts(files);
<snip>
function [d, f] = myfileparts (x)
   [d, f, ext] = cellfun (@(x) fileparts (x), x, "UniformOutput",  
false);
   f = cellfun (@(x, y) sprintf ("%s%s", x, y), f, ext, ...
                "UniformOutput", false);
   idx = cellfun (@(x) isdir (x), x);
   d(idx) = "";
   f(idx) = x(idx);
endfunction

Ben



More information about the Bug-octave mailing list