summaryrefslogtreecommitdiffstats
path: root/src/ogAdmServer.c
diff options
context:
space:
mode:
authorOpenGnSys Support Team <soporte-og@soleta.eu>2021-03-19 14:48:27 +0100
committerOpenGnSys Support Team <soporte-og@soleta.eu>2021-03-19 14:48:34 +0100
commitf844a1b6bcee3107fc6669479dea728b39d7b74d (patch)
tree47feea0b4ec253f7f2c0619a8faf0f13189c0a47 /src/ogAdmServer.c
parente6c2c26f09b65e4c4817ab4f77d4a08e52bd121d (diff)
#971 check for NULL serial number
ogclient might return an empty serial number.
Diffstat (limited to 'src/ogAdmServer.c')
-rw-r--r--src/ogAdmServer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ogAdmServer.c b/src/ogAdmServer.c
index fa7e29a..0500496 100644
--- a/src/ogAdmServer.c
+++ b/src/ogAdmServer.c
@@ -61,7 +61,7 @@ bool actualizaConfiguracion(struct og_dbi *dbi, char *cfg, int ido)
if (i == 0 && c == 1) {
splitCadena(ptrDual, ptrCfg[0], '=');
ser = ptrDual[1];
- if (strlen(ser) > 0) {
+ if (ser && strlen(ser) > 0) {
// Solo actualizar si número de serie no existía.
result = dbi_conn_queryf(dbi->conn,
"UPDATE ordenadores SET numserie='%s'"