Back to index

lightning-sunbird  0.9+nobinonly
TestVersionComparator.cpp File Reference
#include "nsVersionComparator.h"
#include <stdio.h>

Go to the source code of this file.


int main (int argc, char **argv)
 The Xalan testcases app.

Function Documentation

int main ( int  argc,
char **  argv 

The Xalan testcases app.

Definition at line 42 of file TestVersionComparator.cpp.

  if (argc != 3) {
    fprintf(stderr, "Usage: %s <versionA> <versionB>\n", argv[0]);
    return 1;

  PRInt32 i = NS_CompareVersions(argv[1], argv[2]);

  char *format;

  if (i < 0)
    format = "%s < %s\n";
  else if (i > 0)
    format = "%s > %s\n";
    format = "%s = %s\n";

  fprintf(stdout, format, argv[1], argv[2]);
  return 0;

Here is the call graph for this function: