Jump to content




FSector resolves mounted paths wrong


  • You cannot reply to this topic
3 replies to this topic

#1 Sewbacca

  • Members
  • 450 posts
  • LocationStar Wars

Posted 10 October 2016 - 03:35 PM

Hey guys,

If you didn't saw it right now, i refer to my post FSector.
To test FSector, i wanna redirect the fs and run a program by shell.run to test if FSector works correctly.
local root = FSector.create(fs.current(), '')
root.mount('rom', '.customFolder/rom')
fs.redirect(FSector.create(root, '.customFolder/BIOS'))
shell.run('rom/programs/shell', '')
fs.redirect(fs.native())
First, i tried shell, but both errors with No such program.
After a few 'prints', i get at the end paths like:
rom/porgrams/rom/programs/ls and rom/porgrams/advanced/rom/programs/ls.
I have no more ideas.
I hope somebody can help me =)
Sewbacca

Edited by Sewbacca, 12 October 2016 - 12:28 PM.


#2 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 11 October 2016 - 04:18 AM

Can you at least narrow it down to a function, and provide sample input for that function along with expected + actual output?

#3 Lupus590

  • Members
  • 2,028 posts
  • LocationUK

Posted 11 October 2016 - 08:50 AM

for functions which don't return a value, does the state of the virtual file system change as expected? - you are debugging feel free to dump it in a global so you can view the raw data

#4 Sewbacca

  • Members
  • 450 posts
  • LocationStar Wars

Posted 12 October 2016 - 12:23 PM

I often print out the data, but the problem doesn't was mounted path, just fs.isDir ^_^ , i used copy and paste, because i am lazy and i forgot to change fs.getFreeSpace into fs.isDir ^^. I update the code on pastebin in a few minutes/seconds.

Edited by Sewbacca, 12 October 2016 - 12:52 PM.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users