+/*
+ * 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 librararies and programs; if not, write
+ * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
+ * Floor, Boston, MA 02110-1301 USA
+ */
/* $XConsortium: rtable4.c /main/5 1996/10/02 17:31:51 drk $ */
/*
* (c) Copyright 1993, 1994 Hewlett-Packard Company
#include <sys/time.h>
#include <sys/signal.h>
#include <rpc/rpc.h>
+#if defined(CSRG_BASED)
+#define MAXINT INT_MAX
+#else
#include <values.h>
+#endif
#include <string.h>
#include <pwd.h>
#ifdef SUNOS
_DtCm_rtable_gmtoff_4_svc(void *args, struct svc_req *svcrq)
{
static long gmtoff;
+#if !defined(CSRG_BASED)
extern long timezone;
+#else
+ struct tm *t;
+#endif
if (debug)
fprintf(stderr, "_DtCm_rtable_gmtoff_4_svc called\n");
+#if defined(CSRG_BASED)
+ t = localtime(time(NULL));
+ gmtoff = t->tm_gmtoff;
+#else
gmtoff = timezone;
+#endif
return(&gmtoff);
}
extern void *
_DtCm_rtable_ping_4_svc(void *args, struct svc_req *svcrq)
{
- char dummy;
-
if (debug)
fprintf(stderr, "_DtCm_rtable_ping_4_svc called\n");
- return((void *)&dummy); /* for RPC reply */
+ return(NULL); /* for RPC reply */
}
extern void