Opened 16 months ago

Last modified 16 months ago

#14336 new bug

TextSearch won't accept "--with-..." as search terms

Reported by: KapiX Owned by: phoudoin
Priority: normal Milestone: Unscheduled
Component: Applications/TextSearch Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All


It seems it's passing the term to grep unescaped, and grep fails with "unrecognized argument".

Change History (2)

comment:1 by phoudoin, 16 months ago

with Regular Expression enabled of not?

A quick check shows that grep -F "--with-..." works, but grep "--with-..." doesn't.

I guess when Regular Expression is enabled, the -e option should be explicitly passed then, as `grep -e "--with-..." works as expected.

  • (a) current vs. (b) proposed

    a b  
    272     if (! fRegularExpression)
    273         argv[argc++] = "-F"; // no a regexp: force fixed string,
     272    argv[argc++] = fRegularExpression ? "-e" : "-F";
Last edited 16 months ago by phoudoin (previous) (diff)

comment:2 by KapiX, 16 months ago

It doesn't work in both cases. Exact term: --with-theme in libreoffice's source directory.

Note: See TracTickets for help on using tickets.