diff options
author | Loïc Hoguin <[email protected]> | 2014-04-08 19:44:05 +0200 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2014-04-08 19:44:05 +0200 |
commit | 7a37fe6b7fb2df472e86760859b1ac805589d383 (patch) | |
tree | ab8240fb7a996b5668398c8dad09eb14adae8c9e /c_src | |
parent | 01e4a7576ed89533a6ec78a3839c37ae06f309e8 (diff) | |
download | esdl2-7a37fe6b7fb2df472e86760859b1ac805589d383.tar.gz esdl2-7a37fe6b7fb2df472e86760859b1ac805589d383.tar.bz2 esdl2-7a37fe6b7fb2df472e86760859b1ac805589d383.zip |
Add typespecs to the sdl_clipboard module
The interface for sdl_clipboard:get_text/0 changed to be
easier to use as errors can happen.
Diffstat (limited to 'c_src')
-rw-r--r-- | c_src/sdl_clipboard.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/c_src/sdl_clipboard.c b/c_src/sdl_clipboard.c index 2ecc485..4ddaaa2 100644 --- a/c_src/sdl_clipboard.c +++ b/c_src/sdl_clipboard.c @@ -30,7 +30,10 @@ NIF_FUNCTION(get_clipboard_text) SDL_free(text); - return term; + return enif_make_tuple2(env, + atom_ok, + term + ); } // has_clipboard_text |