|
View:
New views
7 Messages
—
Rating Filter:
Alert me
|
|
|
dir on Octave 3.2.0 on VistaHi,
I tried to do a 'dir' command on Octave 3.2.0 on Vista, but it crashed (see below). The same thing seems to work on XP. I localized the problem to the strftime call in dir.m, but didn't have the time to dig into it any further. Still being new to Octave, I decided to ask here first before filing a bug report. Is this a known thing, or some stupid mistake on my side? Best, Koen GNU Octave, version 3.2.0 Copyright (C) 2009 John W. Eaton and others. This is free software; see the source code for copying conditions. There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For details, type `warranty'. Octave was configured for "i686-pc-mingw32". Additional information about Octave is available at http://www.octave.org. Please contribute if you find this software useful. For more information, visit http://www.octave.org/help-wanted.html Report bugs to <bug@...> (but first, please read http://www.octave.org/bugs.html to learn how to write a helpful report). For information about changes from previous versions, type `news'. octave-3.2.0.exe:1:C:\Program Files\Octave\bin > dir error: memory exhausted or requested size too large for range of Octave's index type -- trying to return to prompt octave-3.2.0.exe:1:C:\Program Files\Octave\bin > dir('c:\'); error: memory exhausted or requested size too large for range of Octave's index type -- trying to return to prompt octave-3.2.0.exe:1:C:\Program Files\Octave\bin > ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Octave-dev mailing list Octave-dev@... https://lists.sourceforge.net/lists/listinfo/octave-dev |
|
|
Re: dir on Octave 3.2.0 on VistaKoen Vermeer wrote:
> Hi, > > I tried to do a 'dir' command on Octave 3.2.0 on Vista, but it crashed > (see below). The same thing seems to work on XP. I localized the problem > to the strftime call in dir.m, but didn't have the time to dig into it > any further. Still being new to Octave, I decided to ask here first > before filing a bug report. Is this a known thing, or some stupid > mistake on my side? > > Best, > Koen > Can you provide more details as to what is the problem you localized? Perhaps a simple call to strftime that shows the crash? benjamin ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Octave-dev mailing list Octave-dev@... https://lists.sourceforge.net/lists/listinfo/octave-dev |
|
|
Re: dir on Octave 3.2.0 on VistaOn Wed, 17 Jun 2009 22:27:11 +0200 Benjamin Lindner <lindnerben@...> wrote
> Koen Vermeer wrote: > > I tried to do a 'dir' command on Octave 3.2.0 on Vista, but it crashed > > (see below). The same thing seems to work on XP. I localized the problem > > to the strftime call in dir.m, but didn't have the time to dig into it > > any further. Still being new to Octave, I decided to ask here first > > before filing a bug report. Is this a known thing, or some stupid > > mistake on my side? > Can you provide more details as to what is the problem you localized? > Perhaps a simple call to strftime that shows the crash? I guess it's related to this: Whenever I do strftime("%T",localtime(#number#)), Octave crashes. This now also happens on my XP box. Please see the output of the Octave session below. Koen GNU Octave, version 3.2.0 Copyright (C) 2009 John W. Eaton and others. This is free software; see the source code for copying conditions. There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For details, type `warranty'. Octave was configured for "i686-pc-mingw32". Additional information about Octave is available at http://www.octave.org. Please contribute if you find this software useful. For more information, visit http://www.octave.org/help-wanted.html Report bugs to <bug@...> (but first, please read http://www.octave.org/bugs.html to learn how to write a helpful report). For information about changes from previous versions, type `news'. warning: mark_as_command is obsolete and will be removed from a future version of Octave octave-3.2.0.exe:1:C:\Octave\3.2.0_gcc-4.3.0\bin > strftime("%T",localtime(12345)) error: memory exhausted or requested size too large for range of Octave's index type -- trying to return to prompt octave-3.2.0.exe:1:C:\Octave\3.2.0_gcc-4.3.0\bin > ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Octave-dev mailing list Octave-dev@... https://lists.sourceforge.net/lists/listinfo/octave-dev |
|
|
|
|
|
Re: dir on Octave 3.2.0 on VistaThat version worked :)
Thanks Phil -----Original Message----- From: Benjamin Lindner [mailto:lindnerben@...] Sent: June-26-09 10:28 AM To: Philippe Lavoie; koen@... Cc: octave-dev@... Subject: Re: [OctDev] dir on Octave 3.2.0 on Vista Philippe Lavoie wrote: >> Hi, >> >> I tried to do a 'dir' command on Octave 3.2.0 on Vista, but it >> crashed (see below). The same thing seems to work on XP. I localized >> the problem to the strftime call in dir.m, but didn't have the time >> to dig into it any further. Still being new to Octave, I decided to >> ask here first before filing a bug report. Is this a known thing, or >> some stupid mistake on my side? >> >> Best, >> Koen > > > I can confirm that dir never worked on Windows Server 2008 nor on Windows 7 (64 bits). > As I don't have Vista nor server nor windows 7, so could you try for me the attched version of dir.m and report back if it still fails? thanks a lot benjamin Confidentiality Message This e-mail and its content is confidential: its privileged information is intended for the exclusive use of the addressee. Any other person is strictly prohibited from disclosing, distributing or reproducing it. If the addressee cannot be reached or is unknown to you, please inform the sender by return e-mail immediately and delete this e-mail message and destroy all copies. Avis de confidentialit? Le pr?sent courriel et son contenu est confidentiel: l'information privil?gi?e est ? l'usage exclusif du destinataire ci-dessus. Toute autre personne est par les pr?sentes avis?e qu'il lui est strictement interdit de le diffuser, le distribuer ou le reproduire. Si le destinataire ne peut ?tre joint ou vous est inconnu, veuillez informer l'exp?diteur par courrier ?lectronique imm?diatement et d?truire ce message et toute copie de celui-ci. ------------------------------------------------------------------------------ _______________________________________________ Octave-dev mailing list Octave-dev@... https://lists.sourceforge.net/lists/listinfo/octave-dev |
|
|
Re: dir on Octave 3.2.0 on VistaPhilippe Lavoie wrote:
>> Hi, >> >> I tried to do a 'dir' command on Octave 3.2.0 on Vista, but it crashed >> (see below). The same thing seems to work on XP. I localized the problem >> to the strftime call in dir.m, but didn't have the time to dig into it >> any further. Still being new to Octave, I decided to ask here first >> before filing a bug report. Is this a known thing, or some stupid >> mistake on my side? >> >> Best, >> Koen > > > I can confirm that dir never worked on Windows Server 2008 nor on Windows 7 (64 bits). > the attched version of dir.m and report back if it still fails? thanks a lot benjamin ## Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 John W. Eaton ## ## This file is part of Octave. ## ## Octave is free software; you can redistribute it and/or modify it ## under the terms of the GNU General Public License as published by ## the Free Software Foundation; either version 3 of the License, or (at ## your option) any later version. ## ## Octave is distributed in the hope that it will be useful, but ## WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ## General Public License for more details. ## ## You should have received a copy of the GNU General Public License ## along with Octave; see the file COPYING. If not, see ## <http://www.gnu.org/licenses/>. ## -*- texinfo -*- ## @deftypefn {Function File} {} dir (@var{directory}) ## @deftypefnx {Function File} {[@var{list}] =} dir (@var{directory}) ## Display file listing for directory @var{directory}. If a return ## value is requested, return a structure array with the fields ## ## @example ## @group ## name ## bytes ## date ## isdir ## statinfo ## @end group ## @end example ## ## @noindent ## in which @code{statinfo} is the structure returned from @code{stat}. ## ## If @var{directory} is not a directory, return information about the ## named @var{filename}. @var{directory} may be a list of directories ## specified either by name or with wildcard characters (like * and ?) ## which will be expanded with glob. ## ## Note that for symbolic links, @code{dir} returns information about ## the file that a symbolic link points to instead of the link itself. ## However, if the link points to a nonexistent file, @code{dir} returns ## information about the link. ## @seealso{ls, stat, lstat, readdir, glob, filesep} ## @end deftypefn ## Author: jwe ## FIXME -- this is quite slow for large directories, so perhaps ## it should be converted to C++. function retval = dir (file) if (nargin == 0) file = "."; elseif (nargin > 1) print_usage (); endif ## Prep the retval. info = struct (zeros (0, 1), {"name", "date", "bytes", "isdir", "datenum", "statinfo"}); if (ischar (file)) if (strcmp (file, "*")) file = "."; endif if (strcmp (file, ".")) flst = {"."}; nf = 1; else flst = glob (file); nf = length (flst); endif ## Determine the file list for the case where a single directory is ## specified. if (nf == 1) fn = flst{1}; [st, err, msg] = stat (fn); if (err < 0) warning ("dir: `stat (%s)' failed: %s", fn, msg); nf = 0; elseif (S_ISDIR (st.mode)) flst = readdir (flst{1}); nf = length (flst); for i = 1:nf flst{i} = fullfile (fn, flst{i}); endfor endif endif if (length (flst) > 0) ## Collect results. for i = nf:-1:1 fn = flst{i}; [st, err, msg] = lstat (fn); if (err < 0) warning ("dir: `lstat (%s)' failed: %s", fn, msg); else ## If we are looking at a link that points to something, ## return info about the target of the link, otherwise, return ## info about the link itself. if (S_ISLNK (st.mode)) [xst, err, msg] = stat (fn); if (! err) st = xst; endif endif [dummy, fn, ext] = fileparts (fn); fn = cstrcat (fn, ext); info(i,1).name = fn; lt = localtime (st.mtime); info(i,1).date = strftime ("%d-%b-%Y %H:%M:%S", lt); info(i,1).bytes = st.size; info(i,1).isdir = S_ISDIR (st.mode); info(i,1).datenum = datenum (lt.year + 1900, lt.mon, lt.mday, lt.hour, lt.min, lt.sec); info(i,1).statinfo = st; endif endfor endif else error ("dir: expecting directory or filename to be a char array"); endif ## Return the output arguments. if (nargout > 0) ## Return the requested structure. retval = info; elseif (length (info) > 0) ## Print the structure to the screen. printf ("%s", list_in_columns ({info.name})); else warning ("dir: nonexistent file `%s'", file); endif endfunction ------------------------------------------------------------------------------ _______________________________________________ Octave-dev mailing list Octave-dev@... https://lists.sourceforge.net/lists/listinfo/octave-dev |
|
|
Re: dir on Octave 3.2.0 on VistaOn Fri, 2009-06-26 at 16:27 +0200, Benjamin Lindner wrote:
> As I don't have Vista nor server nor windows 7, so could you try for me > the attched version of dir.m and report back if it still fails? I quickly ran it on the machine on which the stock dir.m failed. This one seems to work fine, although I didn't have the time to test it thoroughly. Thanks! Koen ------------------------------------------------------------------------------ _______________________________________________ Octave-dev mailing list Octave-dev@... https://lists.sourceforge.net/lists/listinfo/octave-dev |
| Free embeddable forum powered by Nabble | Forum Help |