test_ipc.c (libextractor-1.10) | : | test_ipc.c (libextractor-1.11) | ||
---|---|---|---|---|
skipping to change at line 147 | skipping to change at line 147 | |||
size_t i; | size_t i; | |||
/* initialize test buffer as expected by test plugin */ | /* initialize test buffer as expected by test plugin */ | |||
for (i = 0; i<sizeof(buf); i++) | for (i = 0; i<sizeof(buf); i++) | |||
buf[i] = (unsigned char) (i % 256); | buf[i] = (unsigned char) (i % 256); | |||
memcpy (buf, "test", 4); | memcpy (buf, "test", 4); | |||
/* change environment to find 'extractor_test' plugin which is | /* change environment to find 'extractor_test' plugin which is | |||
not installed but should be in the current directory (or .libs) | not installed but should be in the current directory (or .libs) | |||
on 'make check' */ | on 'make check' */ | |||
if (0 != putenv ("LIBEXTRACTOR_PREFIX=." PATH_SEPARATOR_STR ".libs/")) | if (0 != putenv ("LIBEXTRACTOR_PREFIX=.:.libs/")) | |||
fprintf (stderr, | fprintf (stderr, | |||
"Failed to update my environment, plugin loading may fail: %s\n", | "Failed to update my environment, plugin loading may fail: %s\n", | |||
strerror (errno)); | strerror (errno)); | |||
pl = EXTRACTOR_plugin_add_config (NULL, "test(test)", | pl = EXTRACTOR_plugin_add_config (NULL, "test(test)", | |||
EXTRACTOR_OPTION_DEFAULT_POLICY); | EXTRACTOR_OPTION_DEFAULT_POLICY); | |||
pl = EXTRACTOR_plugin_add_config (pl, "test2(test2)", | pl = EXTRACTOR_plugin_add_config (pl, "test2(test2)", | |||
EXTRACTOR_OPTION_DEFAULT_POLICY); | EXTRACTOR_OPTION_DEFAULT_POLICY); | |||
if (NULL == pl) | if (NULL == pl) | |||
{ | { | |||
fprintf (stderr, "failed to load test plugin\n"); | fprintf (stderr, "failed to load test plugin\n"); | |||
End of changes. 1 change blocks. | ||||
1 lines changed or deleted | 1 lines changed or added |