Skip to content

AFNI/NIfTI Server

Sections
Personal tools
You are here: Home » AFNI » Documentation

Doxygen Source Code Documentation


Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals   Search  

l_ge.c File Reference

#include "f2c.h"

Go to the source code of this file.


Functions

integer s_cmp (char *, char *, ftnlen, ftnlen)
logical l_ge (char *a, char *b, ftnlen la, ftnlen lb)

Function Documentation

logical l_ge char *    a,
char *    b,
ftnlen    la,
ftnlen    lb
 

Definition at line 8 of file l_ge.c.

References a, and s_cmp().

00010 {
00011 return(s_cmp(a,b,la,lb) >= 0);
00012 }

integer s_cmp char *   ,
char *   ,
ftnlen   ,
ftnlen   
 

Definition at line 8 of file s_cmp.c.

00010 {
00011 register unsigned char *a, *aend, *b, *bend;
00012 a = (unsigned char *)a0;
00013 b = (unsigned char *)b0;
00014 aend = a + la;
00015 bend = b + lb;
00016 
00017 if(la <= lb)
00018         {
00019         while(a < aend)
00020                 if(*a != *b)
00021                         return( *a - *b );
00022                 else
00023                         { ++a; ++b; }
00024 
00025         while(b < bend)
00026                 if(*b != ' ')
00027                         return( ' ' - *b );
00028                 else    ++b;
00029         }
00030 
00031 else
00032         {
00033         while(b < bend)
00034                 if(*a == *b)
00035                         { ++a; ++b; }
00036                 else
00037                         return( *a - *b );
00038         while(a < aend)
00039                 if(*a != ' ')
00040                         return(*a - ' ');
00041                 else    ++a;
00042         }
00043 return(0);
00044 }
 

Powered by Plone

This site conforms to the following standards: