improve sensorservice's dumpsys

it now displays the reported trigger mode properly, as well as
the number and type of the last received data

Change-Id: I2ff64b32ab71f1332bc2e09671c8c02bb9550490
diff --git a/services/sensorservice/SensorFusion.cpp b/services/sensorservice/SensorFusion.cpp
index a0a17da..4014477 100644
--- a/services/sensorservice/SensorFusion.cpp
+++ b/services/sensorservice/SensorFusion.cpp
@@ -136,9 +136,9 @@
     return mAcc.getMinDelay();
 }
 
-void SensorFusion::dump(String8& result, char* buffer, size_t SIZE) {
+void SensorFusion::dump(String8& result) {
     const Fusion& fusion(mFusion);
-    snprintf(buffer, SIZE, "9-axis fusion %s (%d clients), gyro-rate=%7.2fHz, "
+    result.appendFormat("9-axis fusion %s (%d clients), gyro-rate=%7.2fHz, "
             "q=< %g, %g, %g, %g > (%g), "
             "b=< %g, %g, %g >\n",
             mEnabled ? "enabled" : "disabled",
@@ -152,7 +152,6 @@
             fusion.getBias().x,
             fusion.getBias().y,
             fusion.getBias().z);
-    result.append(buffer);
 }
 
 // ---------------------------------------------------------------------------