bugGNU Octave - Bugs: bug #64377, fullfile produces incorrect result...


bug #64377: fullfile produces incorrect result on empty cell array

Submitter:  None
Submitted:  Mon 03 Jul 2023 02:37:22 PM UTC
Category:  Octave Function Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Regression
Status:  Fixed Assigned to:  None
Originator Name:  iamn Originator Email:  -email is unavailable-
Open/Closed:  * Closed Release:  * 8.1.0
Operating System:  * Any Fixed Release:  8.3.0
Planned Release:  8.3.0
* Mandatory Fields

Add a New Comment Rich Markup

Tue 04 Jul 2023 06:10:23 PM UTC, comment #4: 

The new test seems to be passing in the CI.

The change will be part of Octave 8.3.0 when it will be released.

Closing as fixed.

Markus Mützel <mmuetzel>
Group Member
Mon 03 Jul 2023 04:48:12 PM UTC, comment #3: 

Should be fixed on the stable branch with this change:

Marking as ready for test.

Markus Mützel <mmuetzel>
Group Member
Mon 03 Jul 2023 03:53:35 PM UTC, comment #2: 

The output in Matlab R2023a:

>> fullfile('path', {'a','b'})

ans =

  1×2 cell array

    {'path\a'}    {'path\b'}

>> fullfile('path', {})

ans =

  0×0 empty cell array

It was still working correctly in Octave 6.4.0.

Markus Mützel <mmuetzel>
Group Member
Mon 03 Jul 2023 02:47:53 PM UTC, comment #1: 

What would be an expected output then in either case?


Dmitri A. Sergatskov <dasergatskov>
Mon 03 Jul 2023 02:37:22 PM UTC, original submission:  

fullfile() operates on strings or cells. so:
      fullfile('path', {'a','b'})
    ans =
      [1,1] = path\a
      [1,2] = path\b

    fullfile('path', {})
    ans = path

This is surely a bug??   {} is not the same as ''



(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by mmuetzel (Posted a comment)
  • -email is unavailable- added by dasergatskov (Posted a comment)
  • -email is unavailable- added by None (Submitted the item)

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only project members can vote.


    Follow 9 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2023-07-04 mmuetzel StatusReady For Test Fixed
        Open/ClosedOpen Closed
    2023-07-03 mmuetzel StatusConfirmed Ready For Test
        Fixed ReleaseNone 8.3.0
        Planned ReleaseNone 8.3.0
    2023-07-03 mmuetzel CategoryNone Octave Function
        Item GroupNone Regression
        StatusNone Confirmed
        Operating SystemMicrosoft Windows Any

    Back to the top

    Powered by Savane 3.12