summaryrefslogtreecommitdiff
path: root/perl/pack.c
diff options
context:
space:
mode:
Diffstat (limited to 'perl/pack.c')
-rw-r--r--perl/pack.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/perl/pack.c b/perl/pack.c
index bd0c715..d30735e 100644
--- a/perl/pack.c
+++ b/perl/pack.c
@@ -136,7 +136,9 @@ static void _msgpack_pack_sv(enc_t *enc, SV* val) {
XS(xs_pack) {
dXSARGS;
- PERL_UNUSED_VAR(items); /* TODO: check argument count */
+ if (items != 2) {
+ Perl_croak(aTHX_ "Usage: Data::MessagePack->pack($dat)");
+ }
SV* val = ST(1);