Re: XForms: a strange error in a Xform application

Stephen Huyssoon (huyssoons@advancia.com)
Wed, 24 Feb 1999 15:21:05 -0600

# To subscribers of the xforms list from Stephen Huyssoon <huyssoons@advancia.com> :

DEFILIPPO@lns.infn.it wrote:

> # To subscribers of the xforms list from <DEFILIPPO@lns.infn.it> :
>
> Hi,
>
> I use Xforms library ver. 0.88 in a application running under UNIX - Solaris on
> different Sun platforms. All run very well, but I have a problem that I am not
> sure that depends directly from my application or from XForm library itself.
> The problem is that, sometime after some hours of correct running the program
> is killed and the following error appears:
>
>
> X Error of failed request: BadLength (poly request too large or internal Xlib
> length error)
> Major opcode of failed request: 56 (X_ChangeGC)
> Serial number of failed request: 5254
> Current serial number in output stream: 5269
>
> Note that never I use directly Xlib functions in my application, but only
> Xforms library functions. Unfortunately
> I do not know well Xlib. Can someone explain me the meaning of this error and if
> I can define a signal to capture the error and to evit that my application is
> killed?
>

The X server recognizes two types of errors, protocol errorsand fatal errors.

Your error is a protocol error.

You can easily install an error handler for protocol errors.
Your handler should write out the error message and take
appropriate action.

For your problem, you might try ignoring the error and see
what happens. The X server request will not complete but
otherwise no adverse events should occur in you application.

I have done this myself and it works quite well.

See either "X Window System" by Scheifler & Gettys or the
O'Reilly "Xlib Programming Manual".

In response to your comments, signals are not involved here.

Of course, if either the X server or the Forms Library is
thrown into an error state you will continue to suffer those
consequences.

Good day and adieu.

--
  (Stephen Huyssoon)
>=========================================>
  (huyssoons@advancia.com)

To Infinity and Beyond! -- Me and Buzz Lightyear

A thing cannot be shown to be so using things that do not allow for the thing to be shown. -- Not Science

Julia's Law of Software Development: Business is business and programming is not. -- Julia

Burt's Principle for Programming: Less is more, and cheese is a fundamental ingredient.

_________________________________________________ To unsubscribe, send the message "unsubscribe" to xforms-request@bob.usuhs.mil or see http://bob.usuhs.mil/mailserv/xforms.html XForms Home Page: http://bragg.phys.uwm.edu/xforms List Archive: http://bob.usuhs.mil/mailserv/list-archives/