Bug 6558 (int-149932)

Summary: ohmd fails if discover_plugins cannot open plugin directory
Product: [Maemo Official Platform] System software Reporter: Tommi Saviranta <wnd+maemo>
Component: OHMAssignee: unassigned <nobody>
Status: RESOLVED FIXED QA Contact: ohm-bugs
Severity: normal    
Priority: Low CC: andre_klapper, eero.tamminen, tri
Version: 5.0/(1.2009.42-11)Keywords: crash, patch
Target Milestone: 5.0/(10.2010.19-1)   
Hardware: N900   
OS: Maemo   
Attachments: make discover_plugins() to return sane values on failed opendir()

Description Tommi Saviranta (reporter) 2009-12-03 18:55:07 UTC
SOFTWARE VERSION:
http://repository.maemo.org fremantle/sdk/free ohm 0.1.2-0maemo30.1+0m5

EXACT STEPS LEADING TO PROBLEM: 
1. Missing ohm plugin directory (/usr/lib/ohm)
2. Run ohmd

EXPECTED OUTCOME:
ohmd runs without plugins (or exits gracefully).

ACTUAL OUTCOME:
ohmd segfaults.

REPRODUCIBILITY:
Always.

EXTRA SOFTWARE INSTALLED:
Irrelevant.

OTHER COMMENTS:
If opendir() fails, discover_plugins() returns FALSE (instead of NULL) without
touching number of plugins. Trivial fix is to set *nplugin = 0 and return NULL.

User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.3a1pre)
Gecko/20091129 Minefield/3.7a1pre
Comment 1 Tommi Saviranta (reporter) 2009-12-03 18:57:23 UTC
Created an attachment (id=1660) [details]
make discover_plugins() to return sane values on failed opendir()
Comment 2 Andre Klapper maemo.org 2009-12-08 17:46:06 UTC
Thanks for reporting this & providing a patch!
Comment 3 Venomrush 2010-03-20 00:53:06 UTC
(In reply to comment #2)
> Thanks for reporting this & providing a patch!
> 

Andre, any idea this patch will be in PR1.2?
Comment 4 Eero Tamminen nokia 2010-03-23 15:16:37 UTC
> Andre, any idea this patch will be in PR1.2?

According to internal bug tracker, the patch is included into Ohmd coming in
PR1.2.  Andre hasn't verified it yet though.
Comment 5 Andre Klapper maemo.org 2010-03-29 13:11:36 UTC
Thanks for the patch again!
This has been fixed for the next public update.

To answer popular followup questions:
 * Nokia does not announce release dates of public updates in advance.
 * There is currently no access to these internal, non-public build versions.
   A Brainstorm proposal to change this exists at
http://maemo.org/community/brainstorm/view/undelayed_bugfix_releases_for_nokia_open_source_packages-002/
Comment 6 Venomrush 2010-03-29 16:55:31 UTC
(In reply to comment #4)

> According to internal bug tracker, the patch is included into Ohmd coming in
> PR1.2.  


(In reply to comment #5)
> Thanks for the patch again!
> This has been fixed for the next public update.
> 

Setting TM to PR1.2