aboutsummaryrefslogtreecommitdiff
path: root/src/hyper
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2013-04-01 01:53:29 +0000
committerdos-reis <gdr@axiomatics.org>2013-04-01 01:53:29 +0000
commit3a4195e4293dce547f9fd671063d9b65ca14cc56 (patch)
tree503e7c0a091920be1626452a1a9ddd4def926836 /src/hyper
parent86c534a99a9eda6be04595e2fecc433e51ddaed2 (diff)
downloadopen-axiom-3a4195e4293dce547f9fd671063d9b65ca14cc56.tar.gz
More C cleanups
Diffstat (limited to 'src/hyper')
-rw-r--r--src/hyper/ex2ht.c3
-rw-r--r--src/hyper/htadd.c3
-rw-r--r--src/hyper/hthits.c3
-rw-r--r--src/hyper/hyper.c4
-rw-r--r--src/hyper/spadbuf.c4
5 files changed, 12 insertions, 5 deletions
diff --git a/src/hyper/ex2ht.c b/src/hyper/ex2ht.c
index bbb1db14..3637776a 100644
--- a/src/hyper/ex2ht.c
+++ b/src/hyper/ex2ht.c
@@ -267,9 +267,10 @@ exToHt(const char* filename)
int
main(int argc, char **argv)
{
+ using namespace OpenAxiom;
int i;
- putenv("LC_ALL=C");
+ oa_setenv("LC_ALL", "C");
setlocale(LC_ALL, "");
if (argc == 1) {
fprintf(stderr, "usage: %s exfile.ht ...\n", argv[0]);
diff --git a/src/hyper/htadd.c b/src/hyper/htadd.c
index d8c32a75..e28bd31d 100644
--- a/src/hyper/htadd.c
+++ b/src/hyper/htadd.c
@@ -91,6 +91,7 @@ int fresh = 0;
int
main(int argc, char **argv)
{
+ using namespace OpenAxiom;
/*int i;*/
char db_dir[256]; /* the directory where the db file is */
char dbfilename[256]; /* the database filename */
@@ -98,7 +99,7 @@ main(int argc, char **argv)
char **fnames = filenames;
short flag; /* flag for deleting or adding */
- putenv("LC_ALL=C");
+ oa_setenv("LC_ALL", "C");
setlocale(LC_ALL, "");
parse_args(argv, db_dir, filenames, &flag);
diff --git a/src/hyper/hthits.c b/src/hyper/hthits.c
index d2e2cfb9..0dd712c5 100644
--- a/src/hyper/hthits.c
+++ b/src/hyper/hthits.c
@@ -413,7 +413,8 @@ cmdline(int argc, char** argv)
int
main(int argc, char** argv)
{
- putenv("LC_ALL=C");
+ using namespace OpenAxiom;
+ oa_setenv("LC_ALL", "C");
setlocale(LC_ALL, "");
cmdline(argc, argv);
regcomp(&reg_pattern, pattern, REG_NEWLINE);
diff --git a/src/hyper/hyper.c b/src/hyper/hyper.c
index e88f63f0..f306e0b8 100644
--- a/src/hyper/hyper.c
+++ b/src/hyper/hyper.c
@@ -52,6 +52,7 @@
#include <locale.h>
#include "debug.h"
+#include "cfuns.h"
#include "sockio.h"
#include "hyper.h"
#include "lex.h"
@@ -196,11 +197,12 @@ clean_socket(void )
int
main(int argc, char **argv)
{
+ using namespace OpenAxiom;
int ret_status;
/* Initialize some global values */
/* fprintf(stderr,"hyper:main:entered\n");*/
- putenv("LC_ALL=C");
+ oa_setenv("LC_ALL", "C");
setlocale(LC_ALL, "");
gArgc = argc;
gArgv = argv;
diff --git a/src/hyper/spadbuf.c b/src/hyper/spadbuf.c
index e173b86f..18f28c0e 100644
--- a/src/hyper/spadbuf.c
+++ b/src/hyper/spadbuf.c
@@ -49,6 +49,7 @@
#include <locale.h>
#include "halloc.h"
#include "bsdsignal.h"
+#include "cfuns.h"
#include "sockio.h"
#include "edible.h"
#include "com.h"
@@ -215,6 +216,7 @@ init_parent(void)
int
main(int argc,char ** argv)
{
+ using namespace OpenAxiom;
/*
* Modified on 6/13/90 for the command line completion abiltities of
* Since I am only calling this program from within spadint, I decided
@@ -223,7 +225,7 @@ main(int argc,char ** argv)
* spadbuf page_name [completion_ files]
*
*/
- putenv("LC_ALL=C");
+ oa_setenv("LC_ALL", "C");
setlocale(LC_ALL, "");
if (argc < 2) {
fprintf(stderr, "Usage : spadbuf page_name [completion_files] \n");