Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

driver incompatibility with R15B #1

Open
moskovich opened this Issue · 0 comments

1 participant

@moskovich

R15B added driver version information. Here is a quick patch to fix this (and also another compiler warning).

diff --git a/c_src/iconv_drv.c b/c_src/iconv_drv.c
index f05ebc4..4b97183 100644
--- a/c_src/iconv_drv.c
+++ b/c_src/iconv_drv.c
@@ -278,7 +278,7 @@ static void iv_close(t_iconvdrv *iv, iconv_t cd)
     return;
 }

-static void iconvdrv_from_erlang(ErlDrvData drv_data, char *buf, int len)
+static void iconvdrv_from_erlang(ErlDrvData drv_data, char *buf, ErlDrvSizeT len)
 {
     t_iconvdrv *iv = (t_iconvdrv *) drv_data;
     char ignore = 0;
@@ -367,5 +367,8 @@ DRIVER_INIT(iconvdrv)
   iconvdrv_driver_entry.driver_name  = "iconv_drv";
   iconvdrv_driver_entry.finish       = NULL;
   iconvdrv_driver_entry.outputv      = NULL;
+  iconvdrv_driver_entry.extended_marker = ERL_DRV_EXTENDED_MARKER;
+  iconvdrv_driver_entry.major_version = ERL_DRV_EXTENDED_MAJOR_VERSION;
+  iconvdrv_driver_entry.minor_version = ERL_DRV_EXTENDED_MINOR_VERSION;
   return &iconvdrv_driver_entry;
 }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.