mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-05 15:55:57 +03:00
Remove some bad assert() statements from the implementations of window
functions percent_rank() and cume_dist(). FossilOrigin-Name: 443f0c286f1659937fd61b4ef2de17d0d015369e5ff5249a9e0c3d0ee4925158
This commit is contained in:
@@ -255,9 +255,8 @@ static void percent_rankStepFunc(
|
||||
struct CallCount *p;
|
||||
assert( nArg==1 );
|
||||
|
||||
assert( sqlite3VdbeAssertAggContext(pCtx) );
|
||||
p = (struct CallCount*)sqlite3_aggregate_context(pCtx, sizeof(*p));
|
||||
if( ALWAYS(p) ){
|
||||
if( p ){
|
||||
if( p->nTotal==0 ){
|
||||
p->nTotal = sqlite3_value_int64(apArg[0]);
|
||||
}
|
||||
@@ -301,9 +300,8 @@ static void cume_distStepFunc(
|
||||
struct CallCount *p;
|
||||
assert( nArg==1 );
|
||||
|
||||
assert( sqlite3VdbeAssertAggContext(pCtx) );
|
||||
p = (struct CallCount*)sqlite3_aggregate_context(pCtx, sizeof(*p));
|
||||
if( ALWAYS(p) ){
|
||||
if( p ){
|
||||
if( p->nTotal==0 ){
|
||||
p->nTotal = sqlite3_value_int64(apArg[0]);
|
||||
}
|
||||
|
Reference in New Issue
Block a user