summaryrefslogtreecommitdiffstats
path: root/sources/client.c
diff options
context:
space:
mode:
authorRoberto Hueso Gómez <rhueso@soleta.eu>2020-06-24 11:05:28 +0200
committerOpenGnSys Support Team <soporte-og@soleta.eu>2020-06-24 11:27:27 +0200
commit9c8e5c710269067859e12474a0803a8f2934136e (patch)
tree214088de31a8f432b145ff327eef8c4c6f62b608 /sources/client.c
parent4397ea8a407146c82198f0c148ffad6a351fecd3 (diff)
#941 Move OG_COMPUTER_NAME_MAXLEN to dbi.h
This parameter is actually a database related parameter so now it is renamed to OG_DB_COMPUTER_NAME_MAXLEN.
Diffstat (limited to 'sources/client.c')
-rw-r--r--sources/client.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sources/client.c b/sources/client.c
index ef665fd..c93c74a 100644
--- a/sources/client.c
+++ b/sources/client.c
@@ -22,13 +22,11 @@
#include <jansson.h>
#include <time.h>
-#define OG_COMPUTER_NAME_MAXLEN 100
-
struct og_computer {
unsigned int id;
unsigned int center;
unsigned int room;
- char name[OG_COMPUTER_NAME_MAXLEN + 1];
+ char name[OG_DB_COMPUTER_NAME_MAXLEN + 1];
unsigned int procedure_id;
};
@@ -75,7 +73,7 @@ static int og_dbi_get_computer_info(struct og_computer *computer,
computer->procedure_id = dbi_result_get_uint(result, "idproautoexec");
strncpy(computer->name,
dbi_result_get_string(result, "nombreordenador"),
- OG_COMPUTER_NAME_MAXLEN);
+ OG_DB_COMPUTER_NAME_MAXLEN);
dbi_result_free(result);
og_dbi_close(dbi);