]> git.vpit.fr Git - perl/modules/Linux-SysInfo.git/commitdiff
Prefer gv_stashpvn() to gv_stashpv()
authorVincent Pit <vince@profvince.com>
Tue, 10 Mar 2009 16:03:09 +0000 (17:03 +0100)
committerVincent Pit <vince@profvince.com>
Tue, 10 Mar 2009 16:03:09 +0000 (17:03 +0100)
SysInfo.xs

index 137884f0384fe661ef8c14ec15094e621631706d..fdb289e362e098082baa99f83bbf18e6c613d401 100644 (file)
@@ -10,7 +10,8 @@
 #include "perl.h"
 #include "XSUB.h"
 
-#define __PACKAGE__ "Linux::SysInfo"
+#define __PACKAGE__     "Linux::SysInfo"
+#define __PACKAGE_LEN__ (sizeof(__PACKAGE__)-1)
 
 /* --- Extended fields ----------------------------------------------------- */
 
@@ -71,7 +72,7 @@ PROTOTYPES: ENABLE
 BOOT:
 {
  HV *stash;
- stash = gv_stashpv(__PACKAGE__, TRUE);
+ stash = gv_stashpvn(__PACKAGE__, __PACKAGE_LEN__, TRUE);
  newCONSTSUB(stash, "LS_HAS_EXTENDED", newSViv(LS_HAS_EXTENDED));
 
  LS_KEY_DEFINE(uptime);