Opened 15 years ago

Closed 4 years ago

#1368 closed defect (fixed)

ACE:init missing in MapGuideCommon lib

Reported by: haris Owned by: brucedechant
Priority: low Milestone:
Component: General Version: 2.2.0
Severity: trivial Keywords:
Cc: External ID:

Description (last modified by brucedechant)

MapGuideCommon ( and others libraries) use ACE without calling ACE::init. ACE::init() is called in MG server and web extension but as other libraries can be used independently it would be appropriate that ACE::init() is called in MapGuideCommon itself.

Shouldn't be a problem to implement this as ACE::init can be called multiple times.

Change History (5)

comment:1 by tomfukushima, 15 years ago

Owner: set to brucedechant

comment:2 by brucedechant, 14 years ago

Cc: bruce.dechant@… removed

comment:3 by brucedechant, 14 years ago

Description: modified (diff)

comment:4 by brucedechant, 14 years ago

This is from the Init_ACE.h file:

namespace ACE {

/

  • This class implements the functions for the initialization and
  • shutting down ACE. These functions are called only once per ACE
  • invokation.
  • @return Returns 0 on success, -1 on failure, and 1 if it had already been
  • called. */

extern ACE_Export int init (void);

From the above we should only be calling ACE::init() once. I did a quick test that called it from inside MapGuideCommon and the server would crash when I tried to shut it down. So I don't think calling it multiple times is a good idea.

What about moving the ACE::init() from the server/web main executables to MapGuideCommon?

comment:5 by jng, 4 years ago

Resolution: fixed
Status: newclosed

Fixed with introduction of MgInitializeLibrary in MapGuide RFC 182

Note: See TracTickets for help on using tickets.