home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / database / ingres / 2328 < prev    next >
Encoding:
Internet Message Format  |  1993-01-21  |  2.8 KB

  1. Xref: sparky comp.databases.ingres:2328 alt.toolkits.xview:1219 comp.windows.x:21390
  2. Path: sparky!uunet!cis.ohio-state.edu!news.sei.cmu.edu!cert!netnews.upenn.edu!kin.lap.upenn.edu!jarnot
  3. From: jarnot@kin.lap.upenn.edu (Kevin J. Jarnot)
  4. Newsgroups: comp.databases.ingres,alt.toolkits.xview,comp.windows.x
  5. Subject: Re: XVIEW and INGRES compatability problem! HELP!
  6. Summary: I wonder if this happens with Oracle and Motif???
  7. Message-ID: <105904@netnews.upenn.edu>
  8. Date: 21 Jan 93 04:07:48 GMT
  9. References: <1993Jan20.040019.11802@BofA.com>
  10. Sender: news@netnews.upenn.edu
  11. Followup-To: comp.databases.ingres
  12. Organization: University of Pennsylvania, Language Analysis Center
  13. Lines: 68
  14. Nntp-Posting-Host: kin.lap.upenn.edu
  15.  
  16. In article <1993Jan20.040019.11802@BofA.com> karl@BofA.COM (Karl Nicholas) writes:
  17. >     I am having a problem with ingres and xview
  18. > in the same program.
  19. >     When I make an xview scrollable panel, 
  20. > and then put in some ingres code (connect to database), 
  21. > I get an alarm clock fault when I hit the xview scroll 
  22. > bar.
  23. >     
  24. >     This would indicate to me that both ingres and
  25. > the xview pacakage are using the Alarm Clock signal
  26. > and not doing it properly?
  27. >     Can anyone confirm or deny this? Has anyone
  28. > else run into this? Has anyone else fixed it?
  29.  
  30.  
  31. [code deleted]
  32.  
  33.     Actually, I just posted the same problem to both alt.toolkits.xview
  34. and comp.windows.x a few days ago.  
  35.  
  36.     Yes, it seems that version 6.4 of Ingres is trapping SIGALRMs for some
  37. reason, which of course plays havoc with the notifier in XView.  In the
  38. scrollbar package, the up and down arrows seem to emit SIGALRMs, which
  39. of course are then trapped by Ingres, causing your app to bletch and
  40. print the cryptic message "Alarm clock" to stderr (Ingres seems to have
  41. error messages rivaling even DOS in clarity...) and exit.
  42.  
  43.     I came up with a quick fix in a sleepless haze over the weekend (don't
  44. you love when problems like this pop up two weeks before a deadline? ;-)
  45. Use the following function call:
  46.  
  47.     notify_set_signal_func(frame, sigint_handler, SIGALRM, NOTIFY_ASYNC);
  48.  
  49. to trap the SIGALRM before Ingres gets ahold of it.  sigint_handler()
  50. is a function that looks something like this:
  51.  
  52.  
  53. Notify_value
  54. sigint_handler(client, sig, when)
  55. Notify_client client;
  56. int sig;
  57. {
  58.     printf("Received signal %d...ignoring it...\n", sig);
  59.     return NOTIFY_DONE;
  60. }
  61.  
  62.  
  63. Seems to work OK as a kludge...
  64.  
  65. And to think I ignored everyone when they insisted I should NOT use
  66. Ingres embedded SQL in my XView gui...something about strange crashes... ;-)
  67.  
  68. Mail me back if you need more info...
  69.  
  70.  
  71.  
  72.  
  73. Take care,
  74.  
  75. Kevin
  76.  
  77. -- 
  78. Kevin J. Jarnot (jarnot@kin.lap.upenn.edu)      | "The monkey-boys are evil - 
  79. Lead Programmer/Analyst/Keyboardist             | Lord Whorfin is supreme..."
  80. Univ. of Pennsylvania Language Analysis Center  |  
  81. 3700 Market St, Suite 202  Phila, PA 19104      |       "Vita Non Jerk"
  82.