Rename getline function to unsafe, to make it greppable.

Now i can trim them one-by-one.
This commit is contained in:
2025-08-23 02:20:05 -04:00
parent f283391b46
commit 412adaa492
11 changed files with 27 additions and 26 deletions

View File

@ -189,7 +189,7 @@ char *get_dpi_dir(char *dpidrc)
return (NULL);
}
while ((rcline = dGetline(In)) != NULL) {
while ((rcline = dGetline_unsafe(In)) != NULL) {
if (strncmp(rcline, "dpi_dir", 7) == 0)
break;
dFree(rcline);
@ -497,7 +497,7 @@ int fill_services_list(struct dp *attlist, int numdpis, Dlist **services_list)
*services_list = dList_new(8);
/* dpidrc parser loop */
for (;(line = dGetline(dpidrc_stream)) != NULL; dFree(line)) {
for (;(line = dGetline_unsafe(dpidrc_stream)) != NULL; dFree(line)) {
st = dParser_parse_rc_line(&line, &service, &path);
if (st < 0) {
MSG_ERR("dpid: Syntax error in %s: service=\"%s\" path=\"%s\"\n",