struct descriptor *XmdsExprGetXd(Widget w) { struct descriptor_xd *ans = (struct descriptor_xd *) XtMalloc(sizeof(struct descriptor_xd)); XmdsExprWidget ew = (XmdsExprWidget) w; char *text = GetString(ew->expr.text_widget); struct descriptor_s text_dsc = {0, DTYPE_T, CLASS_S, (char *) 0}; text_dsc.length = strlen(text); text_dsc.pointer = text; ResetErrors(); *ans = empty_xd; if (ew->expr.is_text) MdsCopyDxXd((struct descriptor *) & text_dsc,ans); else { int status; int old_def; int def_nid = GetDefaultNid(ew); if (def_nid != -1) { TreeGetDefaultNid(&old_def); TreeSetDefaultNid(def_nid); } status = (*ew->expr.compile) (&text_dsc,ans MDS_END_ARG); if ((status & 1) == 0) { TdiComplain(w); XtFree((char *)ans); ans = 0; } if (def_nid != -1) TreeSetDefaultNid(old_def); } return (struct descriptor *) ans; }
OdbcConnection::~OdbcConnection() { Disconnect(); ResetErrors(); }
OdbcConnection::~OdbcConnection() { Disconnect(); ResetErrors(); delete m_lock; }