Android Room:应用程序突然崩溃(致命信号 11 (SIGSEGV)、代码 1 (SEGV_MAPERR)、故障地址 0x0)

And*_*rew 7 android kotlin android-room

我的问题是,我的应用程序突然崩溃,我不知道为什么。这种情况发生不规律,但我认为这与我的房间数据库有关。我尝试提供尽可能多的信息:

数据库

@Database(entities = [ProductCacheEntity::class], version = 1)
@TypeConverters(Converters::class)
abstract class ShoppingCartDatabase : RoomDatabase() {
    abstract fun shopDao(): ShoppingCartDao

    companion object {
        const val DATABASE_NAME = "shop_db"
    }
}
Run Code Online (Sandbox Code Playgroud)

DAO

@Dao
interface ShoppingCartDao {
    @Insert(onConflict = OnConflictStrategy.IGNORE)
    suspend fun insert(productCacheEntity: ProductCacheEntity): Long

    @Transaction
    suspend fun upsert(productCacheEntity: ProductCacheEntity) {
        val id = insert(productCacheEntity)
        if (productExists(id)) increaseQuantityById(productCacheEntity.id)
    }

    @Query("UPDATE products SET quantity = quantity + 1 WHERE ID = :id")
    suspend fun increaseQuantityById(id: Int)

    @Query("UPDATE products SET quantity = quantity - 1 WHERE ID = :id")
    suspend fun decreaseQuantityById(id: Int)

    @Query("DELETE FROM products WHERE id = :id")
    suspend fun deleteProductById(id: Int)

    @Query("SELECT * FROM products")
    fun getAllProducts(): LiveData<List<ProductCacheEntity>>

    @Query("SELECT SUM(price * quantity) FROM products")
    fun getSummedPrice(): LiveData<Float>

    private fun productExists(id: Long): Boolean = id == -1L
}
Run Code Online (Sandbox Code Playgroud)

分段

@AndroidEntryPoint
class ShoppingCartFragment(
    private val shoppingCartAdapter: ShoppingCartListAdapter,
    private val cacheMapper: ShopCacheMapper
) : Fragment(R.layout.fragment_shopping_cart), ShoppingCartListAdapter.OnItemClickListener {
    private val shoppingCartViewModel: ShoppingCartViewModel by viewModels()
    private val shoppingCartBinding: FragmentShoppingCartBinding by viewBinding()
   // private val shoppingCartAdapter = ShoppingCartListAdapter()

    override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
        super.onViewCreated(view, savedInstanceState)
        shoppingCartAdapter.clickHandler(this)
        bindObjects()
        observeList()
    }

    private fun observeList() {
        shoppingCartViewModel.productList.observe(viewLifecycleOwner, shoppingCartAdapter::submitList)
    }

    private fun bindObjects() = with(shoppingCartBinding) {
        adapter = shoppingCartAdapter
        viewModel = shoppingCartViewModel
        lifecycleOwner = viewLifecycleOwner
    }

    override fun forwardCardClick(productCacheEntity: ProductCacheEntity) {
        val product = cacheMapper.mapFromEntity(productCacheEntity)
        val action = ShoppingCartFragmentDirections.actionShoppingCartFragmentToShopItemFragment(product)
        findNavController().navigate(action)

    }

    override fun fordwardBtnIncreaseClick(id: Int) {
        shoppingCartViewModel.increaseProductQuantityById(id)
    }

    override fun fordwardBtnDecreaseClick(id: Int) {
        shoppingCartViewModel.decreaseProductQuantityById(id)
    }

    override fun forwardBtnDeleteClick(id: Int) {
        shoppingCartViewModel.deleteProductById(id)
    }

    override fun onDestroyView() {
        requireView().findViewById<RecyclerView>(R.id.rv_shopping_cart).adapter = null
        super.onDestroyView()
    }
Run Code Online (Sandbox Code Playgroud)

列表适配器

class ShoppingCartListAdapter @Inject constructor() : ListAdapter<ProductCacheEntity, ShoppingCartListAdapter.ProductViewHolder>(Companion) {
    private lateinit var clickListener: OnItemClickListener

    companion object: DiffUtil.ItemCallback<ProductCacheEntity>() {
        override fun areItemsTheSame(oldItem: ProductCacheEntity, newItem: ProductCacheEntity): Boolean = oldItem.id == newItem.id
        override fun areContentsTheSame(oldItem: ProductCacheEntity, newItem: ProductCacheEntity): Boolean = oldItem == newItem
    }

    inner class ProductViewHolder(val binding: ShoppingCartListItemBinding): RecyclerView.ViewHolder(binding.root)

    override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ProductViewHolder {
        val layoutInflater = LayoutInflater.from(parent.context)
        val binding = ShoppingCartListItemBinding.inflate(layoutInflater, parent, false)
        return ProductViewHolder(binding).also {
            with(binding) {
                ivProduct.setOnClickListener { clickListener.forwardCardClick(binding.product!!) }
                tvTitle.setOnClickListener { clickListener.forwardCardClick(binding.product!!) }
                btnIncrease.setOnClickListener { clickListener.fordwardBtnIncreaseClick(binding.product!!.id) }
                btnDecrease.setOnClickListener { clickListener.fordwardBtnDecreaseClick(binding.product!!.id) }
                btnDelete.setOnClickListener { clickListener.forwardBtnDeleteClick(binding.product!!.id) }
            }
        }
    }

    override fun onBindViewHolder(holder: ProductViewHolder, position: Int) {
        val currentProduct = getItem(position) ?: return
        holder.binding.product = currentProduct
        holder.binding.btnDecrease.isEnabled = currentProduct.quantity > 1
        holder.binding.executePendingBindings()
    }

    interface OnItemClickListener {
        fun forwardCardClick(productCacheEntity: ProductCacheEntity)
        fun fordwardBtnIncreaseClick(id: Int)
        fun fordwardBtnDecreaseClick(id: Int)
        fun forwardBtnDeleteClick(id: Int)
    }

    fun clickHandler(clickEventHandler: OnItemClickListener) {
        clickListener = clickEventHandler
    }
}
Run Code Online (Sandbox Code Playgroud)

ViewModel(从另一个片段添加产品)

class ShopItemViewModel @ViewModelInject constructor(
    private val shopCacheMapper: ShopCacheMapper,
    private val shoppingCartDB: ShoppingCartDao
) : ViewModel() {
    fun insertOrUpdateProduct(product: Product) = viewModelScope.launch {
        val cacheEntity = shopCacheMapper.mapToEntity(product)
        shoppingCartDB.upsert(cacheEntity)
    }
}
Run Code Online (Sandbox Code Playgroud)

ViewModel 2(用于购物车片段)

class ShoppingCartViewModel @ViewModelInject constructor(
    private val shopDB: ShoppingCartDao
): ViewModel() {
    val productList: LiveData<List<ProductCacheEntity>> = shopDB.getAllProducts()
    val summedPrice: LiveData<Float> = shopDB.getSummedPrice()

    fun increaseProductQuantityById(id: Int) = viewModelScope.launch {
        shopDB.increaseQuantityById(id)
    }

    fun decreaseProductQuantityById(id: Int) = viewModelScope.launch {
        shopDB.decreaseQuantityById(id)
    }

    fun deleteProductById(id: Int) = viewModelScope.launch {
        shopDB.deleteProductById(id)
    }
}
Run Code Online (Sandbox Code Playgroud)

堆栈跟踪一

--------- beginning of crash
2020-10-16 13:09:08.638 11560-11669/com.example.app A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x40 in tid 11669 (Thread-5), pid 11560 (com.example.app)
2020-10-16 13:09:08.678 11707-11707/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
2020-10-16 13:09:08.678 11707-11707/? A/DEBUG: Build fingerprint: 'google/sdk_gphone_x86/generic_x86:10/QSR1.200715.002/6695061:userdebug/dev-keys'
2020-10-16 13:09:08.678 11707-11707/? A/DEBUG: Revision: '0'
2020-10-16 13:09:08.678 11707-11707/? A/DEBUG: ABI: 'x86'
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG: Timestamp: 2020-10-16 11:09:08+0000
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG: pid: 11560, tid: 11669, name: Thread-5  >>> com.example.app <<<
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG: uid: 10133
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x40
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG: Cause: null pointer dereference
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG: Abort message: 'Check failed: throw_dex_pc < accessor.InsnsSizeInCodeUnits() (throw_dex_pc=21634, accessor.InsnsSizeInCodeUnits()=0) '
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG:     eax 00000000  ebx ecfeea74  ecx edfee140  edx f181b801
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG:     edi bfe10c88  esi d8b6a8a0
2020-10-16 13:09:08.679 11707-11707/? A/DEBUG:     ebp bfe10a38  esp bfe109f0  eip ecf0ec29
2020-10-16 13:09:08.735 11707-11707/? A/DEBUG: backtrace:
2020-10-16 13:09:08.735 11707-11707/? A/DEBUG:     NOTE: Function names and BuildId information is missing for some frames due
2020-10-16 13:09:08.735 11707-11707/? A/DEBUG:     NOTE: to unreadable libraries. For unwinds of apps, only shared libraries
2020-10-16 13:09:08.735 11707-11707/? A/DEBUG:     NOTE: found under the lib/ directory are readable.
2020-10-16 13:09:08.735 11707-11707/? A/DEBUG:     NOTE: On this device, run setenforce 0 to make the libraries readable.
2020-10-16 13:09:08.735 11707-11707/? A/DEBUG:       #00 pc 005c5c29  /apex/com.android.runtime/lib/libart.so (art::StackDumpVisitor::StartMethod(art::ArtMethod*, unsigned int)+41) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.736 11707-11707/? A/DEBUG:       #01 pc 00491ec0  /apex/com.android.runtime/lib/libart.so (art::MonitorObjectsStackVisitor::VisitFrame()+80) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.736 11707-11707/? A/DEBUG:       #02 pc 0058c8f8  /apex/com.android.runtime/lib/libart.so (_ZN3art12StackVisitor9WalkStackILNS0_16CountTransitionsE0EEEvb+2008) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.736 11707-11707/? A/DEBUG:       #03 pc 005b6bfe  /apex/com.android.runtime/lib/libart.so (art::Thread::DumpJavaStack(std::__1::basic_ostream<char, std::__1::char_traits<char>>&, bool, bool) const+1022) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.736 11707-11707/? A/DEBUG:       #04 pc 005b1fe9  /apex/com.android.runtime/lib/libart.so (art::Thread::DumpStack(std::__1::basic_ostream<char, std::__1::char_traits<char>>&, bool, BacktraceMap*, bool) const+1017) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.736 11707-11707/? A/DEBUG:       #05 pc 005ace61  /apex/com.android.runtime/lib/libart.so (art::Thread::Dump(std::__1::basic_ostream<char, std::__1::char_traits<char>>&, bool, BacktraceMap*, bool) const+65) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.736 11707-11707/? A/DEBUG:       #06 pc 005d2cd1  /apex/com.android.runtime/lib/libart.so (art::DumpCheckpoint::Run(art::Thread*)+929) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.736 11707-11707/? A/DEBUG:       #07 pc 005cb034  /apex/com.android.runtime/lib/libart.so (art::ThreadList::RunCheckpoint(art::Closure*, art::Closure*)+1556) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #08 pc 005c9be4  /apex/com.android.runtime/lib/libart.so (art::ThreadList::Dump(std::__1::basic_ostream<char, std::__1::char_traits<char>>&, bool)+1620) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #09 pc 005796f0  /apex/com.android.runtime/lib/libart.so (art::AbortState::DumpAllThreads(std::__1::basic_ostream<char, std::__1::char_traits<char>>&, art::Thread*) const+448) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #10 pc 00564d30  /apex/com.android.runtime/lib/libart.so (art::Runtime::Abort(char const*)+1536) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #11 pc 000249b3  /apex/com.android.runtime/lib/libartbase.so (_ZNSt3__110__function6__funcIPFvPKcENS_9allocatorIS5_EES4_EclEOS3_+35) (BuildId: b3a3a0a741f44556d02d009140734527)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #12 pc 0000bac7  /system/lib/libbase.so (android::base::LogMessage::~LogMessage()+727) (BuildId: e6c80e0dfebf299cd41f1c732ad018a9)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #13 pc 001b85bc  /apex/com.android.runtime/lib/libart.so (art::ThrowNullPointerExceptionFromDexPC(bool, unsigned int)+499) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #14 pc 00331cf1  /apex/com.android.runtime/lib/libart.so (art::interpreter::ThrowNullPointerExceptionFromInterpreter()+33) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #15 pc 0034055a  /apex/com.android.runtime/lib/libart.so (void art::interpreter::ExecuteSwitchImplCpp<false, false>(art::interpreter::SwitchImplContext*)+31834) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #16 pc 00145b52  /apex/com.android.runtime/lib/libart.so (ExecuteSwitchImplAsm+18) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #17 pc 0000170c  [anon:dalvik-/system/framework/framework.jar-transformed-transformed-transformed-transformed]
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #18 pc 002f8f92  /apex/com.android.runtime/lib/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.1175793267244191248+690) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #19 pc 002ffe19  /apex/com.android.runtime/lib/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+217) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #20 pc 0032c17e  /apex/com.android.runtime/lib/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+958) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #21 pc 0033edd3  /apex/com.android.runtime/lib/libart.so (void art::interpreter::ExecuteSwitchImplCpp<false, false>(art::interpreter::SwitchImplContext*)+25811) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #22 pc 00145b52  /apex/com.android.runtime/lib/libart.so (ExecuteSwitchImplAsm+18) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #23 pc 0032f624  /system/framework/framework.jar (android.database.AbstractCursor.moveToPosition)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #24 pc 002f8f92  /apex/com.android.runtime/lib/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.1175793267244191248+690) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #25 pc 002ffe19  /apex/com.android.runtime/lib/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+217) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #26 pc 0032c17e  /apex/com.android.runtime/lib/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+958) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #27 pc 0033edd3  /apex/com.android.runtime/lib/libart.so (void art::interpreter::ExecuteSwitchImplCpp<false, false>(art::interpreter::SwitchImplContext*)+25811) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #28 pc 00145b52  /apex/com.android.runtime/lib/libart.so (ExecuteSwitchImplAsm+18) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #29 pc 0032f600  /system/framework/framework.jar (android.database.AbstractCursor.moveToNext)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #30 pc 002f8f92  /apex/com.android.runtime/lib/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.1175793267244191248+690) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #31 pc 002ffe19  /apex/com.android.runtime/lib/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+217) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #32 pc 0032c17e  /apex/com.android.runtime/lib/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+958) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #33 pc 0033ee45  /apex/com.android.runtime/lib/libart.so (void art::interpreter::ExecuteSwitchImplCpp<false, false>(art::interpreter::SwitchImplContext*)+25925) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #34 pc 00145b52  /apex/com.android.runtime/lib/libart.so (ExecuteSwitchImplAsm+18) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #35 pc 0002834c  [anon:dalvik-classes.dex extracted in memory from /data/local/tmp/perfd/sqlite-inspection.jar] (androidx.sqlite.inspection.SqliteInspector.querySchema)
2020-10-16 13:09:08.737 11707-11707/? A/DEBUG:       #36 pc 002f8f92  /apex/com.android.runtime/lib/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.1175793267244191248+690) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #37 pc 002ffe19  /apex/com.android.runtime/lib/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+217) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #38 pc 0032c17e  /apex/com.android.runtime/lib/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+958) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #39 pc 0033b651  /apex/com.android.runtime/lib/libart.so (void art::interpreter::ExecuteSwitchImplCpp<false, false>(art::interpreter::SwitchImplContext*)+11601) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #40 pc 00145b52  /apex/com.android.runtime/lib/libart.so (ExecuteSwitchImplAsm+18) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #41 pc 00028010  [anon:dalvik-classes.dex extracted in memory from /data/local/tmp/perfd/sqlite-inspection.jar] (androidx.sqlite.inspection.SqliteInspector.handleGetSchema)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #42 pc 002f8f92  /apex/com.android.runtime/lib/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.1175793267244191248+690) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #43 pc 002ffe19  /apex/com.android.runtime/lib/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+217) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #44 pc 0032c17e  /apex/com.android.runtime/lib/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+958) (BuildId: fe49ff2b6f401678e4775fb2121e4ea4)
2020-10-16 13:09:08.738 11707-11707/? A/DEBUG:       #45 pc 0033b651  /apex/com.android.runtime/lib/libart.so (voi

小智 3

如果我打开数据库检查器,我也会遇到同样的不规则崩溃。我以为问题出在我的代码中,但事实并非如此。当我停止使用数据库检查器时,我再也没有遇到过这种崩溃