Re: question about program execution

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Paolo Galtieri wrote:
> I have a strange problem that I'm not quite sure what the issue is or how to
> fix it.

It doesn't seem to need fixing.

[...]

> Note I have setup nautilus so that when I open a jar file it runs java -jar
> on that file.  This works and the program does execute.  However, rather
> than looking for the file in the local directory which I would expect to be
> /media/USB, since that is where I went to to run the program, it is looking

The "local directory" is the one which was CWD at the time the launch
took place, not the one where the file being viewed (your jar file)
resides. That's your home directory.

> for the files in my home directory.  The only way I have managed to get
> things to work is to copy the data files to my home directory before running
> the program.  This seems strange to me.  Is this normal behavior or is this
> some sort of security policy?

It is normal and expected behavior. Your file browser, when it got
launched, had your home directory as its CWD. That doesn't change
just because it is showing you files in other directories. Essentially,
it's just a fancy ls command. You wouldn't expect an ls to change
your CWD, would you?

Mike
-- 
p="p=%c%s%c;main(){printf(p,34,p,34);}";main(){printf(p,34,p,34);}
Oppose globalization and One World Governments like the UN.
This message made from 100% recycled bits.
You have found the bank of Larn.
I speak only for myself, and I am unanimous in that!
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [Fedora Magazine]     [Fedora News]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Maintainers]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [Fedora Fonts]     [ATA RAID]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [SSH]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Tux]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Asterisk PBX]     [Fedora Sparc]     [Fedora Universal Network Connector]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux