Skip to content

Commit

Permalink
Allow compilation with glib < 2.36
Browse files Browse the repository at this point in the history
Signed-off-by: Jack Kenrick <github@jack.fr.eu.org>
Jack Kenrick committed Mar 3, 2015
1 parent 5cd111b commit e7a8974
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions duperemove.c
Original file line number Diff line number Diff line change
@@ -285,7 +285,11 @@ int main(int argc, char **argv)
digest_tree = RB_ROOT;

/* Parse options might change this so set a default here */
#if GLIB_CHECK_VERSION(2,36,0)
io_threads = g_get_num_processors();
#else
io_threads = sysconf(_SC_NPROCESSORS_ONLN);
#endif

if (parse_options(argc, argv)) {
usage(argv[0]);

0 comments on commit e7a8974

Please sign in to comment.