+/*
+ * CDE - Common Desktop Environment
+ *
+ * Copyright (c) 1993-2012, The Open Group. All rights reserved.
+ *
+ * These libraries and programs are free software; you can
+ * redistribute them and/or modify them under the terms of the GNU
+ * Lesser General Public License as published by the Free Software
+ * Foundation; either version 2 of the License, or (at your option)
+ * any later version.
+ *
+ * These libraries and programs are distributed in the hope that
+ * they will be useful, but WITHOUT ANY WARRANTY; without even the
+ * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+ * PURPOSE. See the GNU Lesser General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with these libraries and programs; if not, write
+ * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
+ * Floor, Boston, MA 02110-1301 USA
+ */
/* $TOG: HelpUtil.c /main/19 1998/04/09 17:43:30 mgreess $ */
/************************************<+>*************************************
****************************************************************************
#include <Xm/MwmUtil.h>
#include <Xm/MessageB.h>
-#include <X11/keysymdef.h>
#include <X11/Shell.h>
#include <X11/Intrinsic.h>
#include <X11/cursorfont.h>
#include "Access.h"
#include "bufioI.h"
#include "DisplayAreaI.h"
+#include "DisplayAreaP.h"
#include <Dt/Help.h>
#include "HelpI.h"
#include "HelpDialogP.h"
#include "HelpUtilI.h"
#include "HelposI.h"
+#include "HyperTextI.h"
+#include "FormatI.h"
#include "MessagesP.h"
#include "HelpQuickD.h"
#include "SetListI.h"
#define HUSET 8 /* message catalog set */
/******** static variables ********/
-static char DirSlash[] = "/";
+
/******** data structures ********/
typedef struct ExecContext
XmString labelString2;
Widget noexecBtn;
Widget execBtn;
- Cursor cursor;
goodCmd = _DtHelpFilterExecCmdStr(helpWidget, executionPolicy,
commandStr, &filteredCmdStr, &invalidAlias,
if (False == useQueryDialog)
{
*ret_filteredCmdStr = NULL;
+ XtFree(filteredCmdStr);
return -1; /* RETURN error */
}
Boolean queryNeeded;
char * filteredCmdStr = NULL;
ExecContext * execContext;
- DtHelpListStruct *pHelpInfo;
XmString labelString;
XmString labelString2;
Widget msgDlg;
following code can fail on IBM platform when XTHREADS and XUSE_MTSAFE_API
are defined.
*/
+/*
_Xgetpwparams pwd_buf;
+*/
struct passwd * pwd_ret;
/** -------------------------------------------------------------- *
Widget shellWidget,
Cursor cursorIn)
{
- static Cursor DfltOnItemCursor = NULL;
+ static Cursor DfltOnItemCursor = 0;
Widget widget;
Widget child;
CompositeWidget comp_widget;
/* Make the target cursor */
- if (cursorIn != NULL)
+ if (cursorIn != 0)
cursor = cursorIn;
else
#if 0
#else
{
_DtHelpProcessLock();
- if (NULL == DfltOnItemCursor)
+ if (0 == DfltOnItemCursor)
{
char *bits;
char *maskBits;
char *pAccessFile = NULL;
char *tmpSpec=NULL;
char *returnStr=NULL;
- char *strtok_ptr;
+ char *strtok_ptr=NULL;
tmpSpec = XtNewString(specification);
char *pAccessFile = NULL;
char *tmpSpec=NULL;
char *returnStr=NULL;
- char *strtok_ptr;
+ char *strtok_ptr=NULL;
tmpSpec = XtNewString(specification);
/* Set the string to the current help dialog */
(void) _DtHelpFormatAsciiStringDynamic(displayArea, userError, &topicHandle);
- /* We ignor the status return here, because if we error out here we are
+ /* We ignore the status return here, because if we error out here we are
* in big trouble because this is an error routine
*/