(file) Return to CommonUTF.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

Diff for /pegasus/src/Pegasus/Common/CommonUTF.cpp between version 1.7.4.1 and 1.8

version 1.7.4.1, 2004/08/20 17:48:55 version 1.8, 2004/10/17 20:39:17
Line 1 
Line 1 
 //%2003////////////////////////////////////////////////////////////////////////  //%2004////////////////////////////////////////////////////////////////////////
 // //
 // Copyright (c) 2000, 2001, 2002  BMC Software, Hewlett-Packard Development  // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
 // Company, L. P., IBM Corp., The Open Group, Tivoli Systems.  // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
 // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.; // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.;
 // IBM Corp.; EMC Corporation, The Open Group. // IBM Corp.; EMC Corporation, The Open Group.
   // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
   // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
 // //
 // Permission is hereby granted, free of charge, to any person obtaining a copy // Permission is hereby granted, free of charge, to any person obtaining a copy
 // of this software and associated documentation files (the "Software"), to // of this software and associated documentation files (the "Software"), to
Line 296 
Line 298 
     return (isValid_U8((const Uint8 *)legal, numBytes));     return (isValid_U8((const Uint8 *)legal, numBytes));
 } }
  
 Boolean isUTF8Str(const char *legal)  
 {  
         /*char tmp[] = {0xCE,0x99,0xCE,0xBF,0xCF,0x8D,0xCE,0xBD,0xCE,  
                       0xB9,0xCE,0xBA,0xCE,0xBF,0xCE,0xBD,0xCF,0x84,  
                       0x00};*/  
 //      char tmp_[] = "class";  
 //      char * tmp = legal;  
         Uint32 count = 0;  
         Uint32 size = strlen(legal);  
 //      printf("size = %d\n",size);  
         while(count<size)  
         {  
 //              printf("count = %d\n",count);  
                 if(isUTF8(&legal[count]) == true){  
                         UTF8_NEXT(legal,count);  
                 }else{  
 //                      printf("bad string\n");  
                         return false;  
                 }  
         }  
 //      printf("good string\n");  
         return true;  
 /*  
         printf("legal = %s\n\n", legal);  
         Uint32 count = 0;  
         Uint32 trailingBytes = 0;  
         Uint32 size = strlen(legal);  
         printf("size of legal is %d\n",size);  
         while(count<size-1)  
         {  
                 printf("count = %d\n", count);  
                 if(isUTF8((char*)&legal[count]) == true){  
                         UTF8_NEXT(legal,trailingBytes);  
                         count += trailingBytes;  
                 } else{  
                         printf("CommonUTF8:: returning false; position[%d]",count);  
                          return false;  
                 }  
         }  
          printf("CommonUTF8:: returning false; position[%d]",count);  
         return true;*/  
 }  
  
 String escapeStringEncoder(const String& Str) String escapeStringEncoder(const String& Str)
 { {


Legend:
Removed from v.1.7.4.1  
changed lines
  Added in v.1.8

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2