}
void
-pve_rados_connect(cluster)
+pve_rados_conf_read_file(cluster, path)
rados_t cluster
-PROTOTYPE: $
+SV *path
+PROTOTYPE: $$
CODE:
{
- DPRINTF("pve_rados_connect\n");
+ char *p = NULL;
- int res = rados_conf_read_file(cluster, NULL);
+ if (SvOK(path)) {
+ p = SvPV_nolen(path);
+ }
+
+ DPRINTF("pve_rados_conf_read_file %s\n", p);
+
+ int res = rados_conf_read_file(cluster, p);
if (res < 0) {
die("rados_conf_read_file failed - %s\n", strerror(-res));
}
+}
+
+void
+pve_rados_connect(cluster)
+rados_t cluster
+PROTOTYPE: $
+CODE:
+{
+ DPRINTF("pve_rados_connect\n");
- res = rados_connect(cluster);
+ int res = rados_connect(cluster);
if (res < 0) {
die("rados_connect failed - %s\n", strerror(-res));
}