Index: heimdal-1.6~git20131117+dfsg/lib/hdb/hdb.c
===================================================================
--- heimdal-1.6~git20131117+dfsg.orig/lib/hdb/hdb.c	2013-11-17 09:03:14.000000000 -0600
+++ heimdal-1.6~git20131117+dfsg/lib/hdb/hdb.c	2014-01-07 05:21:21.960047762 -0600
@@ -393,6 +393,10 @@
 {
     struct cb_s *cb_ctx = (struct cb_s *)userctx;
 
+    if (cb_ctx->h == NULL) {
+        cb_ctx->h = (struct hdb_method *) plug;
+    }
+
     if (strncmp (cb_ctx->filename, cb_ctx->h->prefix, strlen(cb_ctx->h->prefix)) == 0) {
 	cb_ctx->residual = cb_ctx->filename + strlen(cb_ctx->h->prefix);
 	return 0;
