mirror of
				https://github.com/sqlite/sqlite.git
				synced 2025-11-03 16:53:36 +03:00 
			
		
		
		
	Add the SQLITE_TESTCTRL_BYTEORDER test control to interrogate SQLite's notion
of the processor byte order and whether the byte order is known at compile-time or determined at run-time. FossilOrigin-Name: 9c6961967ae00e563ebe2859eaf2639a79f2cb01
This commit is contained in:
		@@ -3027,6 +3027,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
 | 
			
		||||
      { "optimizations",         SQLITE_TESTCTRL_OPTIMIZATIONS          },
 | 
			
		||||
      { "iskeyword",             SQLITE_TESTCTRL_ISKEYWORD              },
 | 
			
		||||
      { "scratchmalloc",         SQLITE_TESTCTRL_SCRATCHMALLOC          },
 | 
			
		||||
      { "byteorder",             SQLITE_TESTCTRL_BYTEORDER              },
 | 
			
		||||
    };
 | 
			
		||||
    int testctrl = -1;
 | 
			
		||||
    int rc = 0;
 | 
			
		||||
@@ -3067,9 +3068,10 @@ static int do_meta_command(char *zLine, struct callback_data *p){
 | 
			
		||||
          break;
 | 
			
		||||
 | 
			
		||||
        /* sqlite3_test_control(int) */
 | 
			
		||||
        case SQLITE_TESTCTRL_PRNG_SAVE:           
 | 
			
		||||
        case SQLITE_TESTCTRL_PRNG_RESTORE:        
 | 
			
		||||
        case SQLITE_TESTCTRL_PRNG_SAVE:
 | 
			
		||||
        case SQLITE_TESTCTRL_PRNG_RESTORE:
 | 
			
		||||
        case SQLITE_TESTCTRL_PRNG_RESET:
 | 
			
		||||
        case SQLITE_TESTCTRL_BYTEORDER:
 | 
			
		||||
          if( nArg==2 ){
 | 
			
		||||
            rc = sqlite3_test_control(testctrl);
 | 
			
		||||
            fprintf(p->out, "%d (0x%08x)\n", rc, rc);
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user