[Xapian-tickets] [Xapian] #802: Omegascript setrelevant should set minargs to be 1 instead of 0
Xapian
nobody at xapian.org
Mon Mar 30 05:11:06 BST 2020
#802: Omegascript setrelevant should set minargs to be 1 instead of 0
---------------------------------+------------------------
Reporter: Gaurav Arora | Owner: Olly Betts
Type: defect | Status: new
Priority: normal | Milestone:
Component: Other | Version:
Severity: normal | Keywords:
Blocked By: | Blocking:
Operating System: All |
---------------------------------+------------------------
setrelevant set the minargs to be 0
```
T(setrelevant, 0, 1, N, Q), // set rset
```
But assumes it has one argument
```
case CMD_setrelevant: {
string::size_type i = 0, j;
while (true) {
j = args[0].find_first_not_of("0123456789", i);
```
It gets a segmentation fault when we add `$setrelevant` to the template
instead of throwing an error message about min-argument.
Its an easy fix so probably can be directly done in repo instead of the
pull request. Happy to open a pull request if it would be helpful.
--
Ticket URL: <https://trac.xapian.org/ticket/802>
Xapian <https://xapian.org/>
Xapian
More information about the Xapian-tickets
mailing list