Changeset 491 for trunk/src/sh_dbIO.c
- Timestamp:
- Oct 31, 2015, 10:36:55 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_dbIO.c
r483 r491 156 156 { 157 157 FILE * fdp; 158 158 159 159 SL_ENTER(_("sh_dbIO_setdataent_old")); 160 160 … … 163 163 if (0 != seek_sof(fdp, line, size, file)) 164 164 SL_RETURN( SL_EREAD, _("sh_dbIO_setdataent_old")); 165 166 lseek(fileno(fdp), ftello(fdp), SEEK_SET); 167 165 168 if (0 != ftruncate(fileno(fdp), ftello(fdp))) 166 169 { … … 406 409 _("There is a record with a bad version number in the file signature database: %s\n"), 407 410 (NULL == filepath) ? _("(null)") : filepath); 408 sh_error_handle((-1), FIL__, __LINE__, 0, MSG_E_SUBGPATH,411 sh_error_handle((-1), file, line, 0, MSG_E_SUBGPATH, 409 412 _("Record with bad version number in file signature database"), 410 413 _("sh_dbIO_getdataent"), … … 1331 1334 if (pushdata_stdout == S_FALSE) 1332 1335 { 1333 sl_write (fd, p, sizeof(sh_filestore_t)); 1334 sl_write_line_fast (fd, fullpath, sl_strlen(fullpath)); 1335 sl_write_line_fast (fd, lpath, sl_strlen(lpath)); 1336 if (SL_ENONE != sl_write (fd, p, sizeof(sh_filestore_t))) 1337 { 1338 char * tmp = sh_util_safe_name(fullpath); 1339 sh_error_handle((-1), FIL__, __LINE__, 0, MSG_E_SUBGPATH, 1340 _("Failed to write record to baseline database"), 1341 _("write_record"), 1342 tmp); 1343 SH_FREE(tmp); 1344 aud_exit(FIL__, __LINE__, EXIT_FAILURE ); 1345 } 1346 if (SL_ENONE != sl_write_line_fast (fd, fullpath, sl_strlen(fullpath))) 1347 { 1348 char * tmp = sh_util_safe_name(fullpath); 1349 sh_error_handle((-1), FIL__, __LINE__, 0, MSG_E_SUBGPATH, 1350 _("Failed to write path to baseline database"), 1351 _("write_record"), 1352 tmp); 1353 SH_FREE(tmp); 1354 aud_exit(FIL__, __LINE__, EXIT_FAILURE ); 1355 } 1356 if (SL_ENONE != sl_write_line_fast (fd, lpath, sl_strlen(lpath))) 1357 { 1358 char * tmp = sh_util_safe_name(fullpath); 1359 sh_error_handle((-1), FIL__, __LINE__, 0, MSG_E_SUBGPATH, 1360 _("Failed to write lpath to baseline database"), 1361 _("write_record"), 1362 tmp); 1363 SH_FREE(tmp); 1364 aud_exit(FIL__, __LINE__, EXIT_FAILURE ); 1365 } 1336 1366 if (attr_string) 1337 1367 sl_write_line_fast (fd, attr_string, sl_strlen(attr_string));
Note:
See TracChangeset
for help on using the changeset viewer.