10-26 09:41:49.406: ERROR/Zygote(32): setreuid() failed. errno: 2
10-26 09:41:59.526: ERROR/Zygote(32): setreuid() failed. errno: 17
10-26 09:42:02.326: ERROR/BatteryService(68): usbOnlinePath not found
10-26 09:42:02.326: ERROR/BatteryService(68): batteryVoltagePath not found
10-26 09:42:02.326: ERROR/BatteryService(68): batteryTemperaturePath not found
10-26 09:42:02.376: ERROR/SurfaceFlinger(68): Couldn't open /sys/power/wait_for_fb_sleep or /sys/power/wait_for_fb_wake
10-26 09:42:09.087: ERROR/EventHub(68): could not get driver version for /dev/input/mouse0, Not a typewriter
10-26 09:42:09.087: ERROR/EventHub(68): could not get driver version for /dev/input/mice, Not a typewriter
10-26 09:42:09.326: ERROR/System(68): Failure starting core service
10-26 09:42:09.326: ERROR/System(68): java.lang.SecurityException
10-26 09:42:09.326: ERROR/System(68): at android.os.BinderProxy.transact(Native Method)
10-26 09:42:09.326: ERROR/System(68): at android.os.ServiceManagerProxy.addService(ServiceManagerNative.java:146)
10-26 09:42:09.326: ERROR/System(68): at android.os.ServiceManager.addService(ServiceManager.java:72)
10-26 09:42:09.326: ERROR/System(68): at com.android.server.ServerThread.run(SystemServer.java:184)
10-26 09:42:10.446: ERROR/SoundPool(68): error loading /system/media/audio/ui/Effect_Tick.ogg
10-26 09:42:10.446: ERROR/SoundPool(68): error loading /system/media/audio/ui/KeypressStandard.ogg
10-26 09:42:10.456: ERROR/SoundPool(68): error loading /system/media/audio/ui/KeypressSpacebar.ogg
10-26 09:42:10.467: ERROR/SoundPool(68): error loading /system/media/audio/ui/KeypressDelete.ogg
10-26 09:42:10.476: ERROR/SoundPool(68): error loading /system/media/audio/ui/KeypressReturn.ogg
10-26 09:42:12.526: ERROR/ThrottleService(68): Could not open GPS configuration file /etc/gps.conf
10-26 09:42:13.876: ERROR/logwrapper(141): executing /system/bin/tc failed: No such file or directory
10-26 09:42:14.016: ERROR/logwrapper(142): executing /system/bin/tc failed: No such file or directory
10-26 09:42:14.087: ERROR/logwrapper(143): executing /system/bin/tc failed: No such file or directory
10-26 09:42:26.962: ERROR/HierarchicalStateMachine(68): TetherMaster - unhandledMessage: msg.what=3
10-26 09:42:46.231: ERROR/AndroidRuntime(278): FATAL EXCEPTION: main
10-26 09:42:46.231: ERROR/AndroidRuntime(278): java.lang.RuntimeException: Unable to start activity ComponentInfo{Hsu.Snake/Hsu.Snake.MainActivity}: android.view.InflateException: Binary XML file line #7: Error inflating class amdroid.basic.lesson48.SnakeView
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2663)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.ActivityThread.access$2300(ActivityThread.java:125)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.os.Handler.dispatchMessage(Handler.java:99)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.os.Looper.loop(Looper.java:123)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.ActivityThread.main(ActivityThread.java:4627)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at java.lang.reflect.Method.invokeNative(Native Method)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at java.lang.reflect.Method.invoke(Method.java:521)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at dalvik.system.NativeStart.main(Native Method)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): Caused by: android.view.InflateException: Binary XML file line #7: Error inflating class amdroid.basic.lesson48.SnakeView
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:576)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.view.LayoutInflater.rInflate(LayoutInflater.java:618)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.view.LayoutInflater.inflate(LayoutInflater.java:407)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.view.LayoutInflater.inflate(LayoutInflater.java:320)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.view.LayoutInflater.inflate(LayoutInflater.java:276)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:198)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.Activity.setContentView(Activity.java:1647)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at Hsu.Snake.MainActivity.onCreate(MainActivity.java:14)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): ... 11 more
10-26 09:42:46.231: ERROR/AndroidRuntime(278): Caused by: java.lang.ClassNotFoundException: amdroid.basic.lesson48.SnakeView in loader dalvik.system.PathClassLoader[/data/app/Hsu.Snake-2.apk]
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:243)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at java.lang.ClassLoader.loadClass(ClassLoader.java:573)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at java.lang.ClassLoader.loadClass(ClassLoader.java:532)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.view.LayoutInflater.createView(LayoutInflater.java:466)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:565)
10-26 09:42:46.231: ERROR/AndroidRuntime(278): ... 20 more

解决方案 »

  1.   

    amdroid.basic.lesson48.SnakeView  这个类找不到 你看一下xml的配置 具体啥原因我也说不上来
      

  2.   

    10-26 09:42:02.326: ERROR/BatteryService(68): usbOnlinePath not found
    10-26 09:42:02.326: ERROR/BatteryService(68): batteryVoltagePath not found
    10-26 09:42:02.326: ERROR/BatteryService(68): batteryTemperaturePath not found
    请问这个报错是什么问题?我从来没见过这个错误额。
      

  3.   

    我也没见过 这种错误你要看关键的地方 比如caused by 后边的(Caused by: java.lang.ClassNotFoundException: )
      

  4.   

    <?xml version="1.0" encoding="utf-8"?>
    <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:background="#404040"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    >
    <android.Hsu.Snake
    android:id="@+id/snake"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    />
    <RelativeLayout
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    >
    <TextView
    android:id="@+id/text"
    android:text="^_^"
    android:visibility="visible"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_centerInParent="true"
    android:gravity="center_horizontal"
    android:textColor="#ff8888ff"
    android:textSize="24sp"
    />
    </RelativeLayout>
    </FrameLayout>