example/subsystem_netconf.c: Discard ]]>]]> and return only XML response

This commit is contained in:
Peter Stuge 2011-07-17 07:52:37 +02:00
parent 7e47bd6640
commit f922df9e1b

View File

@ -85,6 +85,10 @@ int netconf_read_until(LIBSSH2_CHANNEL *channel, const char *endtag, char *buf,
} while (!endreply || !specialsequence);
/* discard the special sequence so that only XML is returned */
rd = specialsequence - buf;
buf[rd] = 0;
return rd;
}