diff options
Diffstat (limited to 'shared/unstable')
-rw-r--r-- | shared/unstable/fragile.c | 7 | ||||
-rw-r--r-- | shared/unstable/fragile.h | 2 |
2 files changed, 7 insertions, 2 deletions
diff --git a/shared/unstable/fragile.c b/shared/unstable/fragile.c index d91ea58..e65e6d4 100644 --- a/shared/unstable/fragile.c +++ b/shared/unstable/fragile.c @@ -15,15 +15,20 @@ int fragile_class_count(void) return (pd_objectmaker->c_nmethod); } -void fragile_class_getnames(t_atom *av) +int fragile_class_getnames(t_atom *av, int maxnames) { int ac = pd_objectmaker->c_nmethod; t_methodentry *mp = pd_objectmaker->c_methods; + if (ac > maxnames) + ac = maxnames; + else + maxnames = ac; while (ac--) { SETSYMBOL(av, mp->me_name); mp++; av++; } + return (maxnames); } /* Raising and voluntary mutation is a method of resolving name clashes. diff --git a/shared/unstable/fragile.h b/shared/unstable/fragile.h index b59bb14..1e2ea0e 100644 --- a/shared/unstable/fragile.h +++ b/shared/unstable/fragile.h @@ -6,7 +6,7 @@ #define __FRAGILE_H__ int fragile_class_count(void); -void fragile_class_getnames(t_atom *av); +int fragile_class_getnames(t_atom *av, int maxnames); void fragile_class_raise(t_symbol *cname, t_newmethod thiscall); t_pd *fragile_class_mutate(t_symbol *cname, t_newmethod thiscall, int ac, t_atom *av); |