/** Helper to build a record content as needed. */
static inline string makeRecordContent(const QType& qtype, const string& content, bool noDot) {
// noDot: for backend storage, pass true. for API users, pass false.
- return DNSRecordContent::mastermake(qtype.getCode(), 1, content)->getZoneRepresentation(noDot);
+ std::unique_ptr<DNSRecordContent> drc(DNSRecordContent::mastermake(qtype.getCode(), 1, content));
+ return drc->getZoneRepresentation(noDot);
}
/** "Normalize" record content for API consumers. */