Use macro SPECPDL_INDEX.
[bpt/emacs.git] / src / sound.c
index 4504e7e..90fe5f5 100644 (file)
@@ -402,7 +402,7 @@ Internal use only, use `play-sound' instead.  */)
   struct sound_device sd;
   struct sound s;
   Lisp_Object args[2];
-  int count = specpdl_ptr - specpdl;
+  int count = SPECPDL_INDEX ();
 
   file = Qnil;
   GCPRO2 (sound, file);