POSTGRESQL_ROW my_postgresql_fetch_row (B_DB *mdb);
int my_postgresql_query (B_DB *mdb, const char *query);
void my_postgresql_data_seek (B_DB *mdb, int row);
-int my_postgresql_currval (B_DB *mdb, char *table_name);
+int my_postgresql_currval (B_DB *mdb, const char *table_name);
void my_postgresql_field_seek (B_DB *mdb, int row);
POSTGRESQL_FIELD * my_postgresql_fetch_field(B_DB *mdb);
db_unlock(mdb);
}
-int my_postgresql_currval(B_DB *mdb, char *table_name)
+int my_postgresql_currval(B_DB *mdb, const char *table_name)
{
// Obtain the current value of the sequence that
// provides the serial value for primary key of the table.
int res;
int count=30;
size_t len;
- char *digest;
+ const char *digest;
char ed1[50];
mdb->esc_name = check_pool_memory_size(mdb->esc_name, mdb->fnl*2+1);
if (rem && j < buflen) {
mask = (1 << rem) - 1;
if (compatible) {
- buf[j++] = base64_digits[((reg & mask) << 6) - rem];
+ buf[j++] = base64_digits[(reg & mask) << 6 - rem];
} else {
buf[j++] = base64_digits[reg & mask];
}
dev->print_name(),
dcr->pool_name,
dcr->media_type);
+ Jmsg(jcr, M_MOUNT, 0, "%s", dev->errmsg);
+ Dmsg1(100, "%s", dev->errmsg);
}
- Jmsg(jcr, M_MOUNT, 0, "%s", dev->errmsg);
- Dmsg1(100, "%s", dev->errmsg);
}
set_jcr_job_status(jcr, JS_WaitMedia);
{"checklabels", store_bit, ITEM(res_dev.cap_bits), CAP_CHECKLABELS, ITEM_DEFAULT, 0},
{"requiresmount", store_bit, ITEM(res_dev.cap_bits), CAP_REQMOUNT, ITEM_DEFAULT, 0},
{"offlineonunmount", store_bit, ITEM(res_dev.cap_bits), CAP_OFFLINEUNMOUNT, ITEM_DEFAULT, 0},
- {"autoselect", store_bit, ITEM(res_dev.autoselect), 1, ITEM_DEFAULT, 1},
+ {"autoselect", store_bool, ITEM(res_dev.autoselect), 1, ITEM_DEFAULT, 1},
{"changerdevice", store_strname,ITEM(res_dev.changer_name), 0, 0, 0},
{"changercommand", store_strname,ITEM(res_dev.changer_command), 0, 0, 0},
{"alertcommand", store_strname,ITEM(res_dev.alert_command), 0, 0, 0},
char *spool_directory; /* Spool file directory */
uint32_t dev_type; /* device type */
uint32_t label_type; /* label type */
- uint32_t autoselect; /* Automatically select from AutoChanger */
+ bool autoselect; /* Automatically select from AutoChanger */
uint32_t drive_index; /* Autochanger drive index */
uint32_t cap_bits; /* Capabilities of this device */
utime_t max_changer_wait; /* Changer timeout */