Opened 7 years ago

Closed 6 years ago

#1704 closed defect (fixed)

Rasql_Segfault from a condenser with mismatching sdom

Reported by: Bang Pham Huu Owned by: dkamov
Priority: major Milestone: 9.7
Component: qlparser Version: development
Keywords: Cc: Dimitar Misev
Complexity: Medium

Description (last modified by Dimitar Misev)

create a 1D collection with sdom([0:100]):

rasql -q 'create collection test1 GreySet1' --user rasadmin --passwd rasadmin
rasql -q 'insert into test1 values $1' --mddtype GreyString --mdddomain [0:100] -f systemtest/testcases_mandatory/test_select/testdata/101.bin --user rasadmin --passwd rasadmin

running this query

rasql -q 'select condense min over i in [10:11] using c[0,i[0]] from test1 as c'

will result in an error in the rasserver logs:

[INFO] - 2018-06-28 14:40:23,122: Request: 'select condense min over i in [10:11] using c[0,i[0]] from test1 as c'... parsing... checking semantics... evaluating... 
[FATAL] - 2018-06-28 14:40:23,123, /home/dimitar/rasdaman/community/src/qlparser/qtdomainoperation.cc:409: Error: QtDomainOperation::evaluate() - The dimension of the subset domain is not equal to the dimension of the subsetted marray. The subset domain dimension is: 2 while the marray domain dimension is: 1
 [INFO] - 2018-06-28 14:40:23,131: Segmentation fault caught, stacktrace:
 [INFO] - 2018-06-28 14:40:23,181: [bt]: (1) /lib/x86_64-linux-gnu/libc.so.6 (??:0) - +0x9ffcf [0x7f901456efcf]
 [INFO] - 2018-06-28 14:40:23,193: [bt]: (2) /home/dimitar/rasdaman/community/src-install/bin/rasserver (??:0) - QtCondenseOp::evaluateScalarOp(std::vector<QtData*, std::allocator<QtData*> >*, BaseType const*, BinaryOp*, r_Minterval)+0xe7 [0x5557c45d63a5]
 [INFO] - 2018-06-28 14:40:23,242: [bt]: (3) /home/dimitar/rasdaman/community/src-install/bin/rasserver (??:0) - QtCondenseOp::evaluate(std::vector<QtData*, std::allocator<QtData*> >*)+0x2ce [0x5557c45d6150]
 [INFO] - 2018-06-28 14:40:23,252: [bt]: (4) /home/dimitar/rasdaman/community/src-install/bin/rasserver (??:0) - QtOperationIterator::next()+0x189 [0x5557c460f055]
 [INFO] - 2018-06-28 14:40:23,300: [bt]: (5) /home/dimitar/rasdaman/community/src-install/bin/rasserver (??:0) - QueryTree::evaluateRetrieval()+0x239 [0x5557c463dddf]
...

Where the error is logged at qlparser/qtdomainoperation.cc:409, an exception should be thrown.

Change History (4)

comment:1 by Vlad Merticariu, 7 years ago

Milestone: 9.5Future

comment:2 by Dimitar Misev, 6 years ago

Component: serverqlparser
Description: modified (diff)
Milestone: Future9.7
Owner: changed from bbell to dkamov
Status: newassigned

The issue is logged but no exception seems to be throws and there's a segfault later on. It should throw an error.

comment:3 by Dimitar Misev, 6 years ago

Description: modified (diff)

comment:4 by Dimitar Misev, 6 years ago

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.