home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / windows / x / intrinsi / 700 < prev    next >
Encoding:
Internet Message Format  |  1993-01-02  |  1.9 KB

  1. Xref: sparky comp.windows.x.intrinsics:700 comp.windows.x.motif:8298
  2. Path: sparky!uunet!wupost!cs.utexas.edu!ut-emx!tivoli!foraker!taylor
  3. From: taylor@foraker.NoSubdomain.NoDomain (Eric Taylor)
  4. Newsgroups: comp.windows.x.intrinsics,comp.windows.x.motif
  5. Subject: Re: setting resources causing crash!!
  6. Message-ID: <7391@tivoli.UUCP>
  7. Date: 2 Jan 93 18:11:52 GMT
  8. References: <1992Dec31.152754.27251@atinc.uucp>
  9. Sender: news@tivoli.UUCP
  10. Followup-To: comp.windows.x.intrinsics
  11. Lines: 22
  12.  
  13. In article <1992Dec31.152754.27251@atinc.uucp>, root@atinc.uucp (Operator) writes:
  14. |> I have created a custom widget which has many resources.  I have noticed recently that when setting resources with XtSetArg before calling XtCreateWidget, that the application core dumps in the XtCreateWidget call.  I don't know if its a certain order whe|> n setting the resources, and if its the number of resources set, but dbx definitely traces the problem in XtCreateWidget(). Actually _XtCreateWidget, which is called by XtCreateWidget(), with a seg violation at the top of memory.
  15. |> 
  16. |> Using XtSetValues seems to work fine.
  17. |> 
  18. |> Can anyone shed some light on this for me. I'm wondering if I have a resource conflict.  I am thinking that the problem exists when looking at the resource list passed down from the application.  My widget code is not called yet, so the resource list migh|> t be clobbering something, maybe.  Help before I tracethrought the Intrinsics with the debugger.
  19.  
  20.  
  21. The order is not important.
  22. Since Create does not work and SetValues does,
  23. I would suspect that your Initialize method
  24. is faulty.
  25.  
  26. Some debuggers are not smart enough to tell you where
  27. you really are (accurately) when you have gone through a function
  28. pointer.  You might be inside your Initialize procedure
  29. and not know it.
  30.  
  31. I would recommend putting "printf"'s in your Initialize procedure.
  32.  
  33. Duplicate resources are not a problem.
  34. The one furthest down in the heirarchy is the one that is used.
  35.