Deployer Segmentation Fault - when using "cd" + tab

Hi.

Problem description: I am following the RTT-exercises and I got a segmentation fault on hello-7-deployment. I succesfully compiled both the hello- and world-xenomai.so. I added the import line to the application.xml. I run the deployer using $ sudo deployer-xenomai -linfo -s application.xml (the hello component has not been loaded at this stage), but when I type "cd Hello.cpp" and press tab (autocomplete), I inmediately get "Segmentation fault". If I type "cd World.cpp" and press tab, I get no segmentation fault.

However, if after a "make clean" (world-xenomai.so is deleted) I try "cd World.cpp" + tab, I do get a segmentation fault. I tried to "cd" to other files, and apparently filenames with a "." in the middle produce this error. A file inside the Debug subdirectory do not result in segmentation fault even if it has a "." in its the middle of its name.

The system: Ubuntu 9.10, xenomai 2.51, rtt 1.10.2.

What other info do you need to track this?

Regards,

Deployer Segmentation Fault - when using "cd" + tab

On Monday 10 May 2010 13:37:42 jpmzometa [..] ... wrote:
> Hi.
>
> Problem description:
> I am following the RTT-exercises and I got a segmentation fault on
> hello-7-deployment. I succesfully compiled both the hello- and
> world-xenomai.so. I added the import line to the application.xml. I run
> the deployer using $ sudo deployer-xenomai -linfo -s application.xml (the
> hello component has not been loaded at this stage), but when I type "cd
> Hello.cpp" and press tab (autocomplete), I inmediately get "Segmentation
> fault". If I type "cd World.cpp" and press tab, I get no segmentation
> fault.
>
> However, if after a "make clean" (world-xenomai.so is deleted) I try "cd
> World.cpp" + tab, I do get a segmentation fault. I tried to "cd" to other
> files, and apparently filenames with a "." in the middle produce this
> error. A file inside the Debug subdirectory do not result in segmentation
> fault even if it has a "." in its the middle of its name.
>
> The system:
> Ubuntu 9.10, xenomai 2.51, rtt 1.10.2.
>

Thanks for reporting, It's fixed on svn trunk.

commit 316a806b5bd541d8922bd6dc57676cf0fed0498b
Author: psoetens <psoetens@ce417995-dfc9-0310-95a0-acdaff106893>
Date: Tue May 11 13:30:39 2010 +0000

taskbrowser: Fix crash when using 'cd filename.ext'

From: Peter Soetens <peter [..] ...>

git-svn-id: https://svn.mech.kuleuven.be/repos/orocos/trunk/ocl@31811
ce417995-dfc9-0310-95a0-acdaff106893

diff --git a/taskbrowser/TaskBrowser.cpp b/taskbrowser/TaskBrowser.cpp
index 3220676..e52fab2 100644
--- a/taskbrowser/TaskBrowser.cpp
+++ b/taskbrowser/TaskBrowser.cpp
@@ -216,6 +216,8 @@ namespace OCL
if ( pos+1 != line.length() ) // bounds check
peer = findPeer( line.substr(pos+1) );

+ if (!peer)
+ return;
//std::string peername = text.substring( pos+1, std::string::npos
);
TaskContext::PeerList v = peer->getPeerList();
for (TaskContext::PeerList::iterator i = v.begin(); i != v.end();
++i) {

Peter

Deployer Segmentation Fault - when using "cd" + tab

On Monday 10 May 2010 13:37:42 jpmzometa [..] ... wrote:
> Hi.
>
> Problem description:
> I am following the RTT-exercises and I got a segmentation fault on
> hello-7-deployment. I succesfully compiled both the hello- and
> world-xenomai.so. I added the import line to the application.xml. I run
> the deployer using $ sudo deployer-xenomai -linfo -s application.xml (the
> hello component has not been loaded at this stage), but when I type "cd
> Hello.cpp" and press tab (autocomplete), I inmediately get "Segmentation
> fault". If I type "cd World.cpp" and press tab, I get no segmentation
> fault.
>
> However, if after a "make clean" (world-xenomai.so is deleted) I try "cd
> World.cpp" + tab, I do get a segmentation fault. I tried to "cd" to other
> files, and apparently filenames with a "." in the middle produce this
> error. A file inside the Debug subdirectory do not result in segmentation
> fault even if it has a "." in its the middle of its name.
>
> The system:
> Ubuntu 9.10, xenomai 2.51, rtt 1.10.2.
>
> What other info do you need to track this?

That's already very informative. Clearly the tab-completion got somewhere a
null pointer.
I hope that you understand that the 'cd' must include a component name and not
a filename (it could have been called 'change component' - 'cc' instead of
'cd'). For now, you'd better avoid completing on file names until we found the
fix.

Peter

Deployer Segmentation Fault - when using "cd" + tab

Hi.

Problem description:
I am following the RTT-exercises and I got a segmentation fault on hello-7-deployment. I succesfully compiled both the hello- and world-xenomai.so. I added the import line to the application.xml. I run the deployer using $ sudo deployer-xenomai -linfo -s application.xml (the hello component has not been loaded at this stage), but when I type "cd Hello.cpp" and press tab (autocomplete), I inmediately get "Segmentation fault". If I type "cd World.cpp" and press tab, I get no segmentation fault.

However, if after a "make clean" (world-xenomai.so is deleted) I try "cd World.cpp" + tab, I do get a segmentation fault. I tried to "cd" to other files, and apparently filenames with a "." in the middle produce this error. A file inside the Debug subdirectory do not result in segmentation fault even if it has a "." in its the middle of its name.

The system:
Ubuntu 9.10, xenomai 2.51, rtt 1.10.2.

What other info do you need to track this?

Regards,