Skip to main content.
home | support | download

Back to List Archive

Re: Split swish-e binary?

From: SRE <eckert(at)not-real.climber.org>
Date: Fri Sep 28 2001 - 18:17:29 GMT
At 09:42 AM 9/28/01, Bill Moseley wrote:
>Right.  There's sill the "swish-search", but it doesn't comment out much
>code anymore (if any?).

It bypasses the open-for-write parts. My comments at the time
indicated that someone with more code familiarity could probably
do a better job, but reducing the memory requirements was not my
first goal: I wanted a binary that couldn't open any file except
for read, and commenting out those parts was relatively easy.

>It probably doesn't matter that much (for size reasons).  Say we could save
>1M of binary size.  Even with no sharing and running 20 Apache child
>processes it's only 20M, which is probably not enough to worry about.

I'm not savvy enough to comment on that. A full-scale effort to do
it right would involve putting the common routines in one library,
the read routines in another, and the index-building-and-writing
routines in a third.

>And params->index_read_only is set when called as swish-search.
>But that's all it does.

So the writing code is still linked in, but not called? And the
switch is set based on the name by which the tool is invoked?
That works for me, but probably not for my sysadmin. He wants
a binary with no possible way to write files...
Received on Fri Sep 28 18:17:53 2001