Guardian Application Conversion Guide
Program Elements Affected by D-Series System Enhancements
Converting C Applications
5–6 096047 Tandem Computers Incorporated
sscanf Function The sscanf function returns a value that is the number of items scanned and converted.
On C-series systems, the sscanf function returns a -1 if no conversion takes place. On
D-series systems, the sscanf function returns a 0 if no conversion takes place. You
must change your programs if they rely on sscanf returning a -1.
Changing Keywords You should change the following keywords in your program:
C-Series Keyword (Superseded) D-Series Keyword
cc_status _cc_status
lowmem _lowmem
extensible _extensible
variable _variable
tal _tal
Replacing Obsolete TAL
Function Declarations
You should declare TAL functions using a format like that used in the following
example:
_tal long
tal_function
(extptr char *p, short i);
Declaring Function
Prototypes
The C-series compiler generates an implicit function prototype at the call to a function
that does not have a function prototype specified in the scope of the call. This implicit
prototyping violates the ANSI standard and results in code that is not portable.
The D-series compiler does not generate these prototypes. You should include a
function prototype within the scope of each call to a function. If you do not include a
function prototype, the compiler promotes parameters at each call site according to the
ANSI standard rules.
Program Elements
Affected by D-Series
System Enhancements
D-Series system changes that enhance system performance can affect a C-series
program running on a D-series system. You may need to modify the following
program elements:
CPU and PIN variables
File-system error numbers
File names, including disk file names, device names, and process file names
Process identifiers, including process IDs, process handles, and process descriptors
Subvolume defaulting in disk file names
Guardian procedure calls