Changeset 2473 in MondoRescue for branches/2.2.9/mondo/src/common
- Timestamp:
- Nov 10, 2009, 2:13:10 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.2.9/mondo/src/common/libmondo-devices.c
r2472 r2473 1946 1946 char *mounted_on_dsf = NULL; 1947 1947 char *not_mounted_on_dsf = NULL; 1948 char token_chars[] =" \t\r\f\a\0 ";1948 char token_chars[] =" \t\r\f\a\0\n"; 1949 1949 1950 1950 while ((token = mr_strtok(pathlist, token_chars, &lastpos)) != NULL) { … … 1965 1965 log_to_screen(" %s\n", mounted_on_dsf); 1966 1966 log_msg (5, "Adding to bkpinfo->exclude_paths due to -E option: %s", mounted_on_dsf); 1967 strcat(bkpinfo->exclude_paths, " "); 1967 1968 strcat(bkpinfo->exclude_paths, mounted_on_dsf); 1968 1969 strcat(bkpinfo->exclude_paths, " "); … … 1977 1978 log_to_screen("Not archiving the following file systems:\n"); 1978 1979 log_to_screen(" %s\n", not_mounted_on_dsf); 1980 strcat(bkpinfo->exclude_paths, " "); 1979 1981 strcat(bkpinfo->exclude_paths, not_mounted_on_dsf); 1980 1982 strcat(bkpinfo->exclude_paths, ""); … … 1989 1991 case -1: 1990 1992 if (mode == 'E') { 1991 strcat(bkpinfo->exclude_paths, token); 1992 strcat(bkpinfo->exclude_paths, " "); 1993 /* Add the token if not already in the list */ 1994 if (strstr(bkpinfo->exclude_paths,token) == NULL) { 1995 strcat(bkpinfo->exclude_paths, " "); 1996 strcat(bkpinfo->exclude_paths, token); 1997 strcat(bkpinfo->exclude_paths, " "); 1998 } 1993 1999 } else { 1994 strcat(bkpinfo->include_paths, token); 1995 strcat(bkpinfo->include_paths, " "); 2000 /* Add the token if not already in the list */ 2001 if (strstr(bkpinfo->include_paths,token) == NULL) { 2002 strcat(bkpinfo->include_paths, " "); 2003 strcat(bkpinfo->include_paths, token); 2004 strcat(bkpinfo->include_paths, " "); 2005 } 1996 2006 } 1997 2007 break; … … 2636 2646 log_it("prefix = %s", bkpinfo->prefix); 2637 2647 log_it("compression = %ld", bkpinfo->compression_level); 2648 log_it("exclude_path = %s", bkpinfo->exclude_paths); 2649 log_it("include_path = %s", bkpinfo->include_paths); 2638 2650 2639 2651 /* Handle devices passed in bkpinfo and print result */ 2640 mr_make_devlist_from_pathlist(bkpinfo->exclude_paths, 'E'); 2641 mr_make_devlist_from_pathlist(bkpinfo->include_paths, 'I'); 2652 /* the mr_make_devlist_from_pathlist function appends 2653 * to the *_paths variables so copy before */ 2654 mr_asprintf(&tmp, "%s ", bkpinfo->exclude_paths); 2655 mr_make_devlist_from_pathlist(tmp, 'E'); 2656 mr_free(tmp); 2657 mr_asprintf(&tmp, "%s ", bkpinfo->include_paths); 2658 mr_make_devlist_from_pathlist(tmp, 'I'); 2659 mr_free(tmp); 2642 2660 2643 2661 log_it("scratchdir = '%s'", bkpinfo->scratchdir);
Note:
See TracChangeset
for help on using the changeset viewer.