Lines Matching refs:buf
559 hal_device_property_get_as_string (HalDevice *device, const char *key, char *buf, size_t bufsize)
565 g_return_val_if_fail (buf != NULL, NULL);
572 strncpy (buf, hal_property_get_string (prop), bufsize);
575 snprintf (buf, bufsize, "%d", hal_property_get_int (prop));
578 snprintf (buf, bufsize, "%llu", (long long unsigned int) hal_property_get_uint64 (prop));
581 snprintf (buf, bufsize, "%f", hal_property_get_double (prop));
584 strncpy (buf, hal_property_get_bool (prop) ? "true" : "false", bufsize);
594 buf[0] = '\t';
604 strncpy (buf + i, str, bufsize - i);
608 buf[i] = '\t';
615 return buf;
617 buf[0] = '\0';