# | Line 22 | Line 22 | struct tmStruct *tmTop = NULL; /* current tone mappin | |
---|---|---|
22 | struct tmPackage *tmPkg[TM_MAXPKG]; | |
23 | int tmNumPkgs = 0; /* number of registered packages */ | |
24 | ||
25 | + | int tmLastError; /* last error incurred by library */ |
26 | + | char *tmLastFunction; /* error-generating function name */ |
27 | ||
28 | + | |
29 | int | |
30 | tmErrorReturn(func, err) /* error return (with message) */ | |
31 | char *func; | |
32 | int err; | |
33 | { | |
34 | + | tmLastFunction = func; |
35 | + | tmLastError = err; |
36 | if (tmTop != NULL && tmTop->flags & TM_F_NOSTDERR) | |
37 | return(err); | |
38 | fputs(func, stderr); |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |