Menu

DSO problem

Help
lolo
2000-06-15
2000-06-16
  • lolo

    lolo - 2000-06-15

    what i do:

    t.h:
    class T : public DSO{
    public:
        T(char *filename):DSO(filename){}
        virtual ~T(){}
        virtual void doit(){}
    };

    derived.cpp
    class Derived : public T{
    public:
        Derived(char *filename):T(filename){}
        virtual ~Derived(){}
        virtual void doit(){cout << " derived ..." << endl;}
    };

    main.cpp:

    main(){
    T *=new T("derived.so");
    }

    it s make a core dump,if someone can help me

     
    • David Sugar

      David Sugar - 2000-06-16

      The issue is search path.  I normally feed absolute paths into DSO to make
      sure the correct DSO image is loaded.  If you build a try-catch handler to catch DSO *, you can print the error message you are getting.  If you have no catch handler, and the DSO fails, it sends a SIGABRT.

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.