Lines Matching full:we

126 	 * put the delimiter back in case we need an error message and  in rep_add()
128 * we then point the node at the new substitution string in rep_add()
262 * NOTE: When the -c option is used, we are called when there was no match
263 * by pat_match() (that means we did match before the inverted sense of
264 * the logic). Now this seems really strange at first, but with -c we
286 * when we are NOT limited to a single match per pattern mark the in pat_sel()
295 * we reach this point only when we allow a single selected match per in pat_sel()
296 * pattern, if the pattern matches a directory and we do not have -d in pat_sel()
297 * (dflag) we are done with this pattern. We may also be handed a file in pat_sel()
298 * in the subtree of a directory. in that case when we are operating in pat_sel()
299 * with -d, this pattern was already selected and we are done in pat_sel()
306 * ok we matched a directory and we are allowing in pat_sel()
311 * If not we will have a big mess. Yup this is another kludge in pat_sel()
316 * so we can copy it. Future matches will be exact prefix match in pat_sel()
352 * we are then done with this pattern, so we delete it from the list in pat_sel()
355 * vague on the interaction of -c -n and -d. We assume that when -c in pat_sel()
357 * In effect we place the order of the flags as having -c last. in pat_sel()
383 * this archive member is "selected" we process and mark the pattern as
387 * skipped and -1 if we are done with all patterns (and pax should quit
399 * if there are no more patterns and we have -n (and not -c) we are in pat_match()
414 * check for a file name match unless we have DIR_MTCH set in in pat_match()
415 * this pattern then we want a prefix match in pat_match()
420 * as we must have -n set for this (but not -d). We can in pat_match()
421 * only match CHILDREN of that directory so we must use in pat_match()
440 * We had a match, now when we invert the sense (-c) we reject this in pat_match()
441 * member. However we have to tag the pattern a being successful, (in a in pat_match()
442 * match, not in selecting an archive member) so we call pat_sel() here. in pat_match()
458 * skipped and -1 if we are done with all patterns (and pax should quit
474 * Ok we found an exact match in fn_match()
568 * expressions, then apply interactive file rename. We apply replacement
569 * string expressions to both filenames and file links (if we didn't the
570 * links would point to the wrong place, and we could never be able to
571 * move an archive that has a file link in it). When we rename files
572 * interactively, we store that mapping (old name to user input name) so
573 * if we spot any file links to the old file name in the future, we will
617 * IMPORTANT: We have a problem. what do we do with symlinks? in mod_name()
618 * Modifying a hard link name makes sense, as we know the file it in mod_name()
620 * wasn't seen because of a read error or a bad archive, we lose in mod_name()
626 * no perfect solution here. So we handle them like hardlinks. Clearly in mod_name()
630 * justify though. We claim that the symlink name is only likely in mod_name()
632 * in that case it should be modified. what we really need to do is to in mod_name()
637 * we have replacement strings, modify the name and the link in mod_name()
669 * 0 process this file, 1 skip this file, -1 we need to exit pax
680 * we get some reasonable input. Archives may have more than one file in tty_rename()
681 * on them with the same name (from updates etc). We print verbose info in tty_rename()
717 * ok the name changed. We may run into links that point at this in tty_rename()
718 * file later. we have to remember where the user sent the file in tty_rename()
745 * It is really hard to deal with symlinks here, we cannot be sure in set_dest()
774 * we shift the or_name to the right enough to tack in the dir_name in fix_path()
775 * at the front. We make sure we have enough space for it all before in fix_path()
776 * we start. since dest always ends in a slash, we skip of or_name in fix_path()
812 * when we find one with a successful substitution, we modify the name
813 * as specified. if required, we print the results. if the resulting name
814 * is empty, we will skip this archive member. We use the regexp(3)
818 * name is the file name we are going to apply the regular expressions to
824 * 0 if substitution was successful, 1 if we are to skip the file (the name
840 char buf1[PAXPATHLEN+1]; /* where we work on the name */ in rep_name()
843 * copy the name into buf1, where we will work on it. We need to keep in rep_name()
844 * the orig string around so we can print out the result of the final in rep_name()
845 * replacement. We build up the final result in nname. inpt points at in rep_name()
846 * the string we apply the regular expression to. prnt is used to in rep_name()
847 * suppress printing when we handle replacements on the link field in rep_name()
863 * the next pattern, or cleanup if we were global in rep_name()
869 * ok we found one. We have three parts, the prefix in rep_name()
872 * the final output buffer (watching to make sure we in rep_name()
887 * final output. If we have problems, skip it. in rep_name()
899 * we set up to look again starting at the first in rep_name()
903 * the string to process). If we are not doing a global in rep_name()
904 * substitution, we will use inpt to copy the tail to in rep_name()
905 * the final result. Make sure we do not overrun the in rep_name()
914 * if the user wants global we keep trying to in rep_name()
915 * substitute until it fails, then we are done. in rep_name()
930 * we had a substitution, copy the last tail piece (if there is in rep_name()
992 * see if we just have an ordinary replacement character in resub()
993 * or we refer to a subexpression. in resub()
1023 * fail if we run out of space or the match string is damaged in resub()