git.stg.codes
/
stg.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
One more stupid comment erased
[stg.git]
/
projects
/
sgconf_xml
/
main.cpp
diff --git
a/projects/sgconf_xml/main.cpp
b/projects/sgconf_xml/main.cpp
index 751a7537bbe32a022923af8be4ac9e025ea84804..03a63a9ada0deb87ca7f990a8f317dbafcd851c9 100644
(file)
--- a/
projects/sgconf_xml/main.cpp
+++ b/
projects/sgconf_xml/main.cpp
@@
-33,9
+33,9
@@
$Date: 2008/01/05 12:11:34 $
#include <arpa/inet.h>
#include <string.h>
#include <arpa/inet.h>
#include <string.h>
+#include "stg/common.h"
+#include "stg/netunit.h"
#include "request.h"
#include "request.h"
-#include "common.h"
-#include "netunit.h"
#define FN_LEN (512)
#define REQ_STR_LEN (300)
#define FN_LEN (512)
#define REQ_STR_LEN (300)
@@
-135,7
+135,6
@@
if (!req->strReq.res_empty())
//-----------------------------------------------------------------------------
int Process(REQUEST * r)
{
//-----------------------------------------------------------------------------
int Process(REQUEST * r)
{
-char errorMsg[MAX_ERR_STR_LEN];
int ret;
char str[2048];
int ret;
char str[2048];
@@
-150,20
+149,17
@@
CreateRequest(r, str);
if ((ret = nt.Connect()) != st_ok)
{
if ((ret = nt.Connect()) != st_ok)
{
- strncpy(errorMsg, nt.GetError(), MAX_ERR_STR_LEN);
- printf("%s", errorMsg);
+ printf("%s\n", nt.GetError().c_str());
return ret;
}
if ((ret = nt.Transact(str)) != st_ok)
{
return ret;
}
if ((ret = nt.Transact(str)) != st_ok)
{
- strncpy(errorMsg, nt.GetError(), MAX_ERR_STR_LEN);
- printf("%s", errorMsg);
+ printf("%s\n", nt.GetError().c_str());
return ret;
}
if ((ret = nt.Disconnect()) != st_ok)
{
return ret;
}
if ((ret = nt.Disconnect()) != st_ok)
{
- strncpy(errorMsg, nt.GetError(), MAX_ERR_STR_LEN);
- printf("%s", errorMsg);
+ printf("%s\n", nt.GetError().c_str());
return ret;
}
return ret;
}