| 1 | /* $Id: crt.cpp,v 1.3 1999-06-25 13:59:01 phaller Exp $ */
|
|---|
| 2 |
|
|---|
| 3 | /*
|
|---|
| 4 | * Project Odin Software License can be found in LICENSE.TXT
|
|---|
| 5 | * Win32 NT Runtime / NTDLL for OS/2
|
|---|
| 6 | * Copyright 1999 Patrick Haller (phaller@gmx.net)
|
|---|
| 7 | */
|
|---|
| 8 |
|
|---|
| 9 | #include <odin.h>
|
|---|
| 10 | #include <stdlib.h>
|
|---|
| 11 | #include <string.h>
|
|---|
| 12 | #include <math.h>
|
|---|
| 13 | #include <ctype.h>
|
|---|
| 14 | #include <wchar.h>
|
|---|
| 15 | #include <wcstr.h>
|
|---|
| 16 | #include <wctype.h>
|
|---|
| 17 |
|
|---|
| 18 | #include "ntdll.h"
|
|---|
| 19 |
|
|---|
| 20 | /*
|
|---|
| 21 | NTDLL.sprintf
|
|---|
| 22 | NTDLL._itoa
|
|---|
| 23 | NTDLL._wcsicmp
|
|---|
| 24 | */
|
|---|
| 25 |
|
|---|
| 26 |
|
|---|
| 27 | /*****************************************************************************
|
|---|
| 28 | * Name :
|
|---|
| 29 | * Purpose :
|
|---|
| 30 | * Parameters:
|
|---|
| 31 | * Variables :
|
|---|
| 32 | * Result :
|
|---|
| 33 | * Remark : NTDLL.882
|
|---|
| 34 | * Status :
|
|---|
| 35 | *
|
|---|
| 36 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 37 | *****************************************************************************/
|
|---|
| 38 |
|
|---|
| 39 | LPWSTR CDECL OS2_wcsupr(LPWSTR str)
|
|---|
| 40 | {
|
|---|
| 41 | DWORD dwIndex;
|
|---|
| 42 |
|
|---|
| 43 | dprintf(("NTDLL: _wcsupr(%08xh)\n",
|
|---|
| 44 | str));
|
|---|
| 45 |
|
|---|
| 46 | for (dwIndex = wcslen((const wchar_t*)str);
|
|---|
| 47 | dwIndex;
|
|---|
| 48 | dwIndex--)
|
|---|
| 49 | {
|
|---|
| 50 | towupper(str[dwIndex]);
|
|---|
| 51 | }
|
|---|
| 52 |
|
|---|
| 53 | return (str);
|
|---|
| 54 | }
|
|---|
| 55 |
|
|---|
| 56 |
|
|---|
| 57 |
|
|---|
| 58 | /*****************************************************************************
|
|---|
| 59 | * Name :
|
|---|
| 60 | * Purpose :
|
|---|
| 61 | * Parameters:
|
|---|
| 62 | * Variables :
|
|---|
| 63 | * Result :
|
|---|
| 64 | * Remark : NTDLL.883
|
|---|
| 65 | * Status :
|
|---|
| 66 | *
|
|---|
| 67 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 68 | *****************************************************************************/
|
|---|
| 69 |
|
|---|
| 70 | double CDECL OS2abs(double d)
|
|---|
| 71 | {
|
|---|
| 72 | dprintf(("NTDLL: abs(%f)\n",
|
|---|
| 73 | d));
|
|---|
| 74 |
|
|---|
| 75 | return (abs(d));
|
|---|
| 76 | }
|
|---|
| 77 |
|
|---|
| 78 |
|
|---|
| 79 | /*****************************************************************************
|
|---|
| 80 | * Name :
|
|---|
| 81 | * Purpose :
|
|---|
| 82 | * Parameters:
|
|---|
| 83 | * Variables :
|
|---|
| 84 | * Result :
|
|---|
| 85 | * Remark : NTDLL.884
|
|---|
| 86 | * Status :
|
|---|
| 87 | *
|
|---|
| 88 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 89 | *****************************************************************************/
|
|---|
| 90 |
|
|---|
| 91 | double CDECL OS2atan(double d)
|
|---|
| 92 | {
|
|---|
| 93 | dprintf(("NTDLL: atan(%f)\n",
|
|---|
| 94 | d));
|
|---|
| 95 |
|
|---|
| 96 | return (atan(d));
|
|---|
| 97 | }
|
|---|
| 98 |
|
|---|
| 99 |
|
|---|
| 100 | /*****************************************************************************
|
|---|
| 101 | * Name :
|
|---|
| 102 | * Purpose :
|
|---|
| 103 | * Parameters:
|
|---|
| 104 | * Variables :
|
|---|
| 105 | * Result :
|
|---|
| 106 | * Remark : NTDLL.885
|
|---|
| 107 | * Status :
|
|---|
| 108 | *
|
|---|
| 109 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 110 | *****************************************************************************/
|
|---|
| 111 |
|
|---|
| 112 | int CDECL OS2atoi(LPSTR str)
|
|---|
| 113 | {
|
|---|
| 114 | dprintf(("NTDLL: atoi(%s)\n",
|
|---|
| 115 | str));
|
|---|
| 116 |
|
|---|
| 117 | return (atoi(str));
|
|---|
| 118 | }
|
|---|
| 119 |
|
|---|
| 120 |
|
|---|
| 121 | /*****************************************************************************
|
|---|
| 122 | * Name :
|
|---|
| 123 | * Purpose :
|
|---|
| 124 | * Parameters:
|
|---|
| 125 | * Variables :
|
|---|
| 126 | * Result :
|
|---|
| 127 | * Remark : NTDLL.886
|
|---|
| 128 | * Status :
|
|---|
| 129 | *
|
|---|
| 130 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 131 | *****************************************************************************/
|
|---|
| 132 |
|
|---|
| 133 | long CDECL OS2atol(LPSTR str)
|
|---|
| 134 | {
|
|---|
| 135 | dprintf(("NTDLL: atol(%s)\n",
|
|---|
| 136 | str));
|
|---|
| 137 |
|
|---|
| 138 | return (atol(str));
|
|---|
| 139 | }
|
|---|
| 140 |
|
|---|
| 141 |
|
|---|
| 142 | /*****************************************************************************
|
|---|
| 143 | * Name :
|
|---|
| 144 | * Purpose :
|
|---|
| 145 | * Parameters:
|
|---|
| 146 | * Variables :
|
|---|
| 147 | * Result :
|
|---|
| 148 | * Remark : NTDLL.887
|
|---|
| 149 | * Status :
|
|---|
| 150 | *
|
|---|
| 151 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 152 | *****************************************************************************/
|
|---|
| 153 |
|
|---|
| 154 | double CDECL OS2ceil(double d)
|
|---|
| 155 | {
|
|---|
| 156 | dprintf(("NTDLL: ceil(%f)\n",
|
|---|
| 157 | d));
|
|---|
| 158 |
|
|---|
| 159 | return (ceil(d));
|
|---|
| 160 | }
|
|---|
| 161 |
|
|---|
| 162 |
|
|---|
| 163 | /*****************************************************************************
|
|---|
| 164 | * Name :
|
|---|
| 165 | * Purpose :
|
|---|
| 166 | * Parameters:
|
|---|
| 167 | * Variables :
|
|---|
| 168 | * Result :
|
|---|
| 169 | * Remark : NTDLL.888
|
|---|
| 170 | * Status :
|
|---|
| 171 | *
|
|---|
| 172 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 173 | *****************************************************************************/
|
|---|
| 174 |
|
|---|
| 175 | double CDECL OS2cos(double d)
|
|---|
| 176 | {
|
|---|
| 177 | dprintf(("NTDLL: cos(%f)\n",
|
|---|
| 178 | d));
|
|---|
| 179 |
|
|---|
| 180 | return (cos(d));
|
|---|
| 181 | }
|
|---|
| 182 |
|
|---|
| 183 |
|
|---|
| 184 | /*****************************************************************************
|
|---|
| 185 | * Name :
|
|---|
| 186 | * Purpose :
|
|---|
| 187 | * Parameters:
|
|---|
| 188 | * Variables :
|
|---|
| 189 | * Result :
|
|---|
| 190 | * Remark : NTDLL.889
|
|---|
| 191 | * Status :
|
|---|
| 192 | *
|
|---|
| 193 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 194 | *****************************************************************************/
|
|---|
| 195 |
|
|---|
| 196 | double CDECL OS2fabs(double d)
|
|---|
| 197 | {
|
|---|
| 198 | dprintf(("NTDLL: fabs(%f)\n",
|
|---|
| 199 | d));
|
|---|
| 200 |
|
|---|
| 201 | return (fabs(d));
|
|---|
| 202 | }
|
|---|
| 203 |
|
|---|
| 204 |
|
|---|
| 205 | /*****************************************************************************
|
|---|
| 206 | * Name :
|
|---|
| 207 | * Purpose :
|
|---|
| 208 | * Parameters:
|
|---|
| 209 | * Variables :
|
|---|
| 210 | * Result :
|
|---|
| 211 | * Remark : NTDLL.890
|
|---|
| 212 | * Status :
|
|---|
| 213 | *
|
|---|
| 214 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 215 | *****************************************************************************/
|
|---|
| 216 |
|
|---|
| 217 | double CDECL OS2floor(double d)
|
|---|
| 218 | {
|
|---|
| 219 | dprintf(("NTDLL: floor(%f)\n",
|
|---|
| 220 | d));
|
|---|
| 221 |
|
|---|
| 222 | return (floor(d));
|
|---|
| 223 | }
|
|---|
| 224 |
|
|---|
| 225 |
|
|---|
| 226 | /*****************************************************************************
|
|---|
| 227 | * Name :
|
|---|
| 228 | * Purpose :
|
|---|
| 229 | * Parameters:
|
|---|
| 230 | * Variables :
|
|---|
| 231 | * Result :
|
|---|
| 232 | * Remark : NTDLL.891
|
|---|
| 233 | * Status :
|
|---|
| 234 | *
|
|---|
| 235 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 236 | *****************************************************************************/
|
|---|
| 237 |
|
|---|
| 238 | int CDECL OS2isalpha(int i)
|
|---|
| 239 | {
|
|---|
| 240 | dprintf(("NTDLL: isalpha(%08xh)\n",
|
|---|
| 241 | i));
|
|---|
| 242 |
|
|---|
| 243 | return (isalpha(i));
|
|---|
| 244 | }
|
|---|
| 245 |
|
|---|
| 246 |
|
|---|
| 247 | /*****************************************************************************
|
|---|
| 248 | * Name :
|
|---|
| 249 | * Purpose :
|
|---|
| 250 | * Parameters:
|
|---|
| 251 | * Variables :
|
|---|
| 252 | * Result :
|
|---|
| 253 | * Remark : NTDLL.892
|
|---|
| 254 | * Status :
|
|---|
| 255 | *
|
|---|
| 256 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 257 | *****************************************************************************/
|
|---|
| 258 |
|
|---|
| 259 | int CDECL OS2isdigit(int i)
|
|---|
| 260 | {
|
|---|
| 261 | dprintf(("NTDLL: isdigit(%08xh)\n",
|
|---|
| 262 | i));
|
|---|
| 263 |
|
|---|
| 264 | return (isdigit(i));
|
|---|
| 265 | }
|
|---|
| 266 |
|
|---|
| 267 |
|
|---|
| 268 | /*****************************************************************************
|
|---|
| 269 | * Name :
|
|---|
| 270 | * Purpose :
|
|---|
| 271 | * Parameters:
|
|---|
| 272 | * Variables :
|
|---|
| 273 | * Result :
|
|---|
| 274 | * Remark : NTDLL.893
|
|---|
| 275 | * Status :
|
|---|
| 276 | *
|
|---|
| 277 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 278 | *****************************************************************************/
|
|---|
| 279 |
|
|---|
| 280 | int CDECL OS2islower(int i)
|
|---|
| 281 | {
|
|---|
| 282 | dprintf(("NTDLL: islower(%08xh)\n",
|
|---|
| 283 | i));
|
|---|
| 284 |
|
|---|
| 285 | return (islower(i));
|
|---|
| 286 | }
|
|---|
| 287 |
|
|---|
| 288 |
|
|---|
| 289 | /*****************************************************************************
|
|---|
| 290 | * Name :
|
|---|
| 291 | * Purpose :
|
|---|
| 292 | * Parameters:
|
|---|
| 293 | * Variables :
|
|---|
| 294 | * Result :
|
|---|
| 295 | * Remark : NTDLL.894
|
|---|
| 296 | * Status :
|
|---|
| 297 | *
|
|---|
| 298 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 299 | *****************************************************************************/
|
|---|
| 300 |
|
|---|
| 301 | int CDECL OS2isprint(int i)
|
|---|
| 302 | {
|
|---|
| 303 | dprintf(("NTDLL: isprint(%08xh)\n",
|
|---|
| 304 | i));
|
|---|
| 305 |
|
|---|
| 306 | return (isprint(i));
|
|---|
| 307 | }
|
|---|
| 308 |
|
|---|
| 309 |
|
|---|
| 310 | /*****************************************************************************
|
|---|
| 311 | * Name :
|
|---|
| 312 | * Purpose :
|
|---|
| 313 | * Parameters:
|
|---|
| 314 | * Variables :
|
|---|
| 315 | * Result :
|
|---|
| 316 | * Remark : NTDLL.895
|
|---|
| 317 | * Status :
|
|---|
| 318 | *
|
|---|
| 319 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 320 | *****************************************************************************/
|
|---|
| 321 |
|
|---|
| 322 | int CDECL OS2isspace(int i)
|
|---|
| 323 | {
|
|---|
| 324 | dprintf(("NTDLL: isspace(%08xh)\n",
|
|---|
| 325 | i));
|
|---|
| 326 |
|
|---|
| 327 | return (isspace(i));
|
|---|
| 328 | }
|
|---|
| 329 |
|
|---|
| 330 |
|
|---|
| 331 | /*****************************************************************************
|
|---|
| 332 | * Name :
|
|---|
| 333 | * Purpose :
|
|---|
| 334 | * Parameters:
|
|---|
| 335 | * Variables :
|
|---|
| 336 | * Result :
|
|---|
| 337 | * Remark : NTDLL.896
|
|---|
| 338 | * Status :
|
|---|
| 339 | *
|
|---|
| 340 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 341 | *****************************************************************************/
|
|---|
| 342 |
|
|---|
| 343 | int CDECL OS2isupper(int i)
|
|---|
| 344 | {
|
|---|
| 345 | dprintf(("NTDLL: isupper(%08xh)\n",
|
|---|
| 346 | i));
|
|---|
| 347 |
|
|---|
| 348 | return (isupper(i));
|
|---|
| 349 | }
|
|---|
| 350 |
|
|---|
| 351 |
|
|---|
| 352 | /*****************************************************************************
|
|---|
| 353 | * Name :
|
|---|
| 354 | * Purpose :
|
|---|
| 355 | * Parameters:
|
|---|
| 356 | * Variables :
|
|---|
| 357 | * Result :
|
|---|
| 358 | * Remark : NTDLL.911
|
|---|
| 359 | * Status :
|
|---|
| 360 | *
|
|---|
| 361 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 362 | *****************************************************************************/
|
|---|
| 363 |
|
|---|
| 364 | LPSTR CDECL OS2sprintf(LPSTR lpstrBuffer,
|
|---|
| 365 | LPSTR lpstrFormat,
|
|---|
| 366 | ...)
|
|---|
| 367 | {
|
|---|
| 368 | va_list argptr; /* -> variable argument list */
|
|---|
| 369 |
|
|---|
| 370 | dprintf(("NTDLL: sprintf(%08xh,%s)\n",
|
|---|
| 371 | lpstrBuffer,
|
|---|
| 372 | lpstrFormat));
|
|---|
| 373 |
|
|---|
| 374 | va_start(argptr,
|
|---|
| 375 | lpstrFormat); /* get pointer to argument list */
|
|---|
| 376 | vsprintf(lpstrBuffer,
|
|---|
| 377 | lpstrFormat,
|
|---|
| 378 | argptr);
|
|---|
| 379 | va_end(argptr); /* done with variable arguments */
|
|---|
| 380 |
|
|---|
| 381 | return (lpstrBuffer);
|
|---|
| 382 | }
|
|---|
| 383 |
|
|---|
| 384 |
|
|---|
| 385 |
|
|---|
| 386 | /*****************************************************************************
|
|---|
| 387 | * Name :
|
|---|
| 388 | * Purpose :
|
|---|
| 389 | * Parameters:
|
|---|
| 390 | * Variables :
|
|---|
| 391 | * Result :
|
|---|
| 392 | * Remark : NTDLL.914
|
|---|
| 393 | * Status :
|
|---|
| 394 | *
|
|---|
| 395 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 396 | *****************************************************************************/
|
|---|
| 397 |
|
|---|
| 398 | LPSTR CDECL OS2strcat( LPSTR str1,
|
|---|
| 399 | const LPSTR str2)
|
|---|
| 400 | {
|
|---|
| 401 | dprintf(("NTDLL: strcat(%s,%s)\n",
|
|---|
| 402 | str1,
|
|---|
| 403 | str2));
|
|---|
| 404 |
|
|---|
| 405 | return (strcat(str1, str2));
|
|---|
| 406 | }
|
|---|
| 407 |
|
|---|
| 408 |
|
|---|
| 409 | /*****************************************************************************
|
|---|
| 410 | * Name :
|
|---|
| 411 | * Purpose :
|
|---|
| 412 | * Parameters:
|
|---|
| 413 | * Variables :
|
|---|
| 414 | * Result :
|
|---|
| 415 | * Remark : NTDLL.915
|
|---|
| 416 | * Status :
|
|---|
| 417 | *
|
|---|
| 418 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 419 | *****************************************************************************/
|
|---|
| 420 |
|
|---|
| 421 | LPSTR CDECL OS2strchr(const LPSTR str,
|
|---|
| 422 | int i)
|
|---|
| 423 | {
|
|---|
| 424 | dprintf(("NTDLL: strchr(%s,%08xh)\n",
|
|---|
| 425 | str,
|
|---|
| 426 | i));
|
|---|
| 427 |
|
|---|
| 428 | return (strchr(str, i));
|
|---|
| 429 | }
|
|---|
| 430 |
|
|---|
| 431 |
|
|---|
| 432 | /*****************************************************************************
|
|---|
| 433 | * Name :
|
|---|
| 434 | * Purpose :
|
|---|
| 435 | * Parameters:
|
|---|
| 436 | * Variables :
|
|---|
| 437 | * Result :
|
|---|
| 438 | * Remark : NTDLL.916
|
|---|
| 439 | * Status :
|
|---|
| 440 | *
|
|---|
| 441 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 442 | *****************************************************************************/
|
|---|
| 443 |
|
|---|
| 444 | int CDECL OS2strcmp(const LPSTR str1,
|
|---|
| 445 | const LPSTR str2)
|
|---|
| 446 | {
|
|---|
| 447 | dprintf(("NTDLL: strcmp(%s,%s)\n",
|
|---|
| 448 | str1,
|
|---|
| 449 | str2));
|
|---|
| 450 |
|
|---|
| 451 | return (strcmp(str1, str2));
|
|---|
| 452 | }
|
|---|
| 453 |
|
|---|
| 454 |
|
|---|
| 455 | /*****************************************************************************
|
|---|
| 456 | * Name :
|
|---|
| 457 | * Purpose :
|
|---|
| 458 | * Parameters:
|
|---|
| 459 | * Variables :
|
|---|
| 460 | * Result :
|
|---|
| 461 | * Remark : NTDLL.917
|
|---|
| 462 | * Status :
|
|---|
| 463 | *
|
|---|
| 464 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 465 | *****************************************************************************/
|
|---|
| 466 |
|
|---|
| 467 | LPSTR CDECL OS2strcpy( LPSTR str1,
|
|---|
| 468 | const LPSTR str2)
|
|---|
| 469 | {
|
|---|
| 470 | dprintf(("NTDLL: strcpy(%s,%s)\n",
|
|---|
| 471 | str1,
|
|---|
| 472 | str2));
|
|---|
| 473 |
|
|---|
| 474 | return (strcpy(str1, str2));
|
|---|
| 475 | }
|
|---|
| 476 |
|
|---|
| 477 |
|
|---|
| 478 | /*****************************************************************************
|
|---|
| 479 | * Name :
|
|---|
| 480 | * Purpose :
|
|---|
| 481 | * Parameters:
|
|---|
| 482 | * Variables :
|
|---|
| 483 | * Result :
|
|---|
| 484 | * Remark : NTDLL.918
|
|---|
| 485 | * Status :
|
|---|
| 486 | *
|
|---|
| 487 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 488 | *****************************************************************************/
|
|---|
| 489 |
|
|---|
| 490 | size_t CDECL OS2strcspn(const LPSTR str1,
|
|---|
| 491 | LPSTR str2)
|
|---|
| 492 | {
|
|---|
| 493 | dprintf(("NTDLL: strcspn(%s,%s)\n",
|
|---|
| 494 | str1,
|
|---|
| 495 | str2));
|
|---|
| 496 |
|
|---|
| 497 | return (strcspn(str1, str2));
|
|---|
| 498 | }
|
|---|
| 499 |
|
|---|
| 500 |
|
|---|
| 501 | /*****************************************************************************
|
|---|
| 502 | * Name :
|
|---|
| 503 | * Purpose :
|
|---|
| 504 | * Parameters:
|
|---|
| 505 | * Variables :
|
|---|
| 506 | * Result :
|
|---|
| 507 | * Remark : NTDLL.919
|
|---|
| 508 | * Status :
|
|---|
| 509 | *
|
|---|
| 510 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 511 | *****************************************************************************/
|
|---|
| 512 |
|
|---|
| 513 | size_t CDECL OS2strlen(const LPSTR str)
|
|---|
| 514 | {
|
|---|
| 515 | dprintf(("NTDLL: strlen(%s)\n",
|
|---|
| 516 | str));
|
|---|
| 517 |
|
|---|
| 518 | return (strlen(str));
|
|---|
| 519 | }
|
|---|
| 520 |
|
|---|
| 521 |
|
|---|
| 522 | /*****************************************************************************
|
|---|
| 523 | * Name :
|
|---|
| 524 | * Purpose :
|
|---|
| 525 | * Parameters:
|
|---|
| 526 | * Variables :
|
|---|
| 527 | * Result :
|
|---|
| 528 | * Remark : NTDLL.920
|
|---|
| 529 | * Status :
|
|---|
| 530 | *
|
|---|
| 531 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 532 | *****************************************************************************/
|
|---|
| 533 |
|
|---|
| 534 | LPSTR CDECL OS2strncat( LPSTR str1,
|
|---|
| 535 | const LPSTR str2,
|
|---|
| 536 | size_t i)
|
|---|
| 537 | {
|
|---|
| 538 | dprintf(("NTDLL: strncat(%s,%s,%08xh)\n",
|
|---|
| 539 | str1,
|
|---|
| 540 | str2,
|
|---|
| 541 | i));
|
|---|
| 542 |
|
|---|
| 543 | return (strncat(str1, str2, i));
|
|---|
| 544 | }
|
|---|
| 545 |
|
|---|
| 546 |
|
|---|
| 547 | /*****************************************************************************
|
|---|
| 548 | * Name :
|
|---|
| 549 | * Purpose :
|
|---|
| 550 | * Parameters:
|
|---|
| 551 | * Variables :
|
|---|
| 552 | * Result :
|
|---|
| 553 | * Remark : NTDLL.921
|
|---|
| 554 | * Status :
|
|---|
| 555 | *
|
|---|
| 556 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 557 | *****************************************************************************/
|
|---|
| 558 |
|
|---|
| 559 | int CDECL OS2strncmp(const LPSTR str1,
|
|---|
| 560 | const LPSTR str2,
|
|---|
| 561 | size_t i)
|
|---|
| 562 | {
|
|---|
| 563 | dprintf(("NTDLL: strncmp(%s,%s,%08xh)\n",
|
|---|
| 564 | str1,
|
|---|
| 565 | str2,
|
|---|
| 566 | i));
|
|---|
| 567 |
|
|---|
| 568 | return (strncmp(str1, str2, i));
|
|---|
| 569 | }
|
|---|
| 570 |
|
|---|
| 571 |
|
|---|
| 572 | /*****************************************************************************
|
|---|
| 573 | * Name :
|
|---|
| 574 | * Purpose :
|
|---|
| 575 | * Parameters:
|
|---|
| 576 | * Variables :
|
|---|
| 577 | * Result :
|
|---|
| 578 | * Remark : NTDLL.922
|
|---|
| 579 | * Status :
|
|---|
| 580 | *
|
|---|
| 581 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 582 | *****************************************************************************/
|
|---|
| 583 |
|
|---|
| 584 | LPSTR CDECL OS2strncpy(const LPSTR str1,
|
|---|
| 585 | const LPSTR str2,
|
|---|
| 586 | size_t i)
|
|---|
| 587 | {
|
|---|
| 588 | dprintf(("NTDLL: strncpy(%s,%s,%08xh)\n",
|
|---|
| 589 | str1,
|
|---|
| 590 | str2,
|
|---|
| 591 | i));
|
|---|
| 592 |
|
|---|
| 593 | return (strncpy(str1, str2, i));
|
|---|
| 594 | }
|
|---|
| 595 |
|
|---|
| 596 |
|
|---|
| 597 | /*****************************************************************************
|
|---|
| 598 | * Name :
|
|---|
| 599 | * Purpose :
|
|---|
| 600 | * Parameters:
|
|---|
| 601 | * Variables :
|
|---|
| 602 | * Result :
|
|---|
| 603 | * Remark : NTDLL.923
|
|---|
| 604 | * Status :
|
|---|
| 605 | *
|
|---|
| 606 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 607 | *****************************************************************************/
|
|---|
| 608 |
|
|---|
| 609 | LPSTR CDECL OS2strpbrk(const LPSTR str1,
|
|---|
| 610 | const LPSTR str2)
|
|---|
| 611 | {
|
|---|
| 612 | dprintf(("NTDLL: strpbrk(%s,%s)\n",
|
|---|
| 613 | str1,
|
|---|
| 614 | str2));
|
|---|
| 615 |
|
|---|
| 616 | return (strpbrk(str1, str2));
|
|---|
| 617 | }
|
|---|
| 618 |
|
|---|
| 619 |
|
|---|
| 620 | /*****************************************************************************
|
|---|
| 621 | * Name :
|
|---|
| 622 | * Purpose :
|
|---|
| 623 | * Parameters:
|
|---|
| 624 | * Variables :
|
|---|
| 625 | * Result :
|
|---|
| 626 | * Remark : NTDLL.924
|
|---|
| 627 | * Status :
|
|---|
| 628 | *
|
|---|
| 629 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 630 | *****************************************************************************/
|
|---|
| 631 |
|
|---|
| 632 | LPSTR CDECL OS2strrchr(const LPSTR str,
|
|---|
| 633 | size_t i)
|
|---|
| 634 | {
|
|---|
| 635 | dprintf(("NTDLL: strrchr(%s,%08xh)\n",
|
|---|
| 636 | str,
|
|---|
| 637 | i));
|
|---|
| 638 |
|
|---|
| 639 | return (strrchr(str, i));
|
|---|
| 640 | }
|
|---|
| 641 |
|
|---|
| 642 |
|
|---|
| 643 | /*****************************************************************************
|
|---|
| 644 | * Name :
|
|---|
| 645 | * Purpose :
|
|---|
| 646 | * Parameters:
|
|---|
| 647 | * Variables :
|
|---|
| 648 | * Result :
|
|---|
| 649 | * Remark : NTDLL.925
|
|---|
| 650 | * Status :
|
|---|
| 651 | *
|
|---|
| 652 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 653 | *****************************************************************************/
|
|---|
| 654 |
|
|---|
| 655 | size_t CDECL OS2strspn(const LPSTR str1,
|
|---|
| 656 | const LPSTR str2)
|
|---|
| 657 | {
|
|---|
| 658 | dprintf(("NTDLL: strspn(%s,%s)\n",
|
|---|
| 659 | str1,
|
|---|
| 660 | str2));
|
|---|
| 661 |
|
|---|
| 662 | return (strspn(str1, str2));
|
|---|
| 663 | }
|
|---|
| 664 |
|
|---|
| 665 |
|
|---|
| 666 | /*****************************************************************************
|
|---|
| 667 | * Name :
|
|---|
| 668 | * Purpose :
|
|---|
| 669 | * Parameters:
|
|---|
| 670 | * Variables :
|
|---|
| 671 | * Result :
|
|---|
| 672 | * Remark : NTDLL.926
|
|---|
| 673 | * Status :
|
|---|
| 674 | *
|
|---|
| 675 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 676 | *****************************************************************************/
|
|---|
| 677 |
|
|---|
| 678 | LPSTR CDECL OS2strstr(const LPSTR str1,
|
|---|
| 679 | const LPSTR str2)
|
|---|
| 680 | {
|
|---|
| 681 | dprintf(("NTDLL: strstr(%s,%s)\n",
|
|---|
| 682 | str1,
|
|---|
| 683 | str2));
|
|---|
| 684 |
|
|---|
| 685 | return (strstr(str1, str2));
|
|---|
| 686 | }
|
|---|
| 687 |
|
|---|
| 688 |
|
|---|
| 689 |
|
|---|
| 690 |
|
|---|
| 691 |
|
|---|
| 692 |
|
|---|
| 693 |
|
|---|
| 694 |
|
|---|
| 695 |
|
|---|
| 696 | /*****************************************************************************
|
|---|
| 697 | * Name :
|
|---|
| 698 | * Purpose :
|
|---|
| 699 | * Parameters:
|
|---|
| 700 | * Variables :
|
|---|
| 701 | * Result :
|
|---|
| 702 | * Remark : NTDLL.934
|
|---|
| 703 | * Status :
|
|---|
| 704 | *
|
|---|
| 705 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 706 | *****************************************************************************/
|
|---|
| 707 |
|
|---|
| 708 | wchar_t* CDECL OS2wcscat( wchar_t* str1,
|
|---|
| 709 | const wchar_t* str2)
|
|---|
| 710 | {
|
|---|
| 711 | dprintf(("NTDLL: wcscat(%08xh,%08xh)\n",
|
|---|
| 712 | str1,
|
|---|
| 713 | str2));
|
|---|
| 714 |
|
|---|
| 715 | return (wcscat(str1, str2));
|
|---|
| 716 | }
|
|---|
| 717 |
|
|---|
| 718 |
|
|---|
| 719 | /*****************************************************************************
|
|---|
| 720 | * Name :
|
|---|
| 721 | * Purpose :
|
|---|
| 722 | * Parameters:
|
|---|
| 723 | * Variables :
|
|---|
| 724 | * Result :
|
|---|
| 725 | * Remark : NTDLL.935
|
|---|
| 726 | * Status :
|
|---|
| 727 | *
|
|---|
| 728 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 729 | *****************************************************************************/
|
|---|
| 730 |
|
|---|
| 731 | wchar_t* CDECL OS2wcschr(const wchar_t* str,
|
|---|
| 732 | int i)
|
|---|
| 733 | {
|
|---|
| 734 | dprintf(("NTDLL: wcschr(%08xh,%08xh)\n",
|
|---|
| 735 | str,
|
|---|
| 736 | i));
|
|---|
| 737 |
|
|---|
| 738 | return (wcschr(str, i));
|
|---|
| 739 | }
|
|---|
| 740 |
|
|---|
| 741 |
|
|---|
| 742 | /*****************************************************************************
|
|---|
| 743 | * Name :
|
|---|
| 744 | * Purpose :
|
|---|
| 745 | * Parameters:
|
|---|
| 746 | * Variables :
|
|---|
| 747 | * Result :
|
|---|
| 748 | * Remark : NTDLL.936
|
|---|
| 749 | * Status :
|
|---|
| 750 | *
|
|---|
| 751 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 752 | *****************************************************************************/
|
|---|
| 753 |
|
|---|
| 754 | int CDECL OS2wcscmp(const wchar_t* str1,
|
|---|
| 755 | const wchar_t* str2)
|
|---|
| 756 | {
|
|---|
| 757 | dprintf(("NTDLL: wcscmp(%08xh,%08xh)\n",
|
|---|
| 758 | str1,
|
|---|
| 759 | str2));
|
|---|
| 760 |
|
|---|
| 761 | return (wcscmp(str1, str2));
|
|---|
| 762 | }
|
|---|
| 763 |
|
|---|
| 764 |
|
|---|
| 765 | /*****************************************************************************
|
|---|
| 766 | * Name :
|
|---|
| 767 | * Purpose :
|
|---|
| 768 | * Parameters:
|
|---|
| 769 | * Variables :
|
|---|
| 770 | * Result :
|
|---|
| 771 | * Remark : NTDLL.937
|
|---|
| 772 | * Status :
|
|---|
| 773 | *
|
|---|
| 774 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 775 | *****************************************************************************/
|
|---|
| 776 |
|
|---|
| 777 | wchar_t* CDECL OS2wcscpy( wchar_t* str1,
|
|---|
| 778 | const wchar_t* str2)
|
|---|
| 779 | {
|
|---|
| 780 | dprintf(("NTDLL: wcscpy(%08xh,%08xh)\n",
|
|---|
| 781 | str1,
|
|---|
| 782 | str2));
|
|---|
| 783 |
|
|---|
| 784 | return (wcscpy(str1, str2));
|
|---|
| 785 | }
|
|---|
| 786 |
|
|---|
| 787 |
|
|---|
| 788 | /*****************************************************************************
|
|---|
| 789 | * Name :
|
|---|
| 790 | * Purpose :
|
|---|
| 791 | * Parameters:
|
|---|
| 792 | * Variables :
|
|---|
| 793 | * Result :
|
|---|
| 794 | * Remark : NTDLL.938
|
|---|
| 795 | * Status :
|
|---|
| 796 | *
|
|---|
| 797 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 798 | *****************************************************************************/
|
|---|
| 799 |
|
|---|
| 800 | size_t CDECL OS2wcscspn(const wchar_t* str1,
|
|---|
| 801 | wchar_t* str2)
|
|---|
| 802 | {
|
|---|
| 803 | dprintf(("NTDLL: wcscspn(%08xh,%08xh)\n",
|
|---|
| 804 | str1,
|
|---|
| 805 | str2));
|
|---|
| 806 |
|
|---|
| 807 | return (wcscspn(str1, str2));
|
|---|
| 808 | }
|
|---|
| 809 |
|
|---|
| 810 |
|
|---|
| 811 | /*****************************************************************************
|
|---|
| 812 | * Name :
|
|---|
| 813 | * Purpose :
|
|---|
| 814 | * Parameters:
|
|---|
| 815 | * Variables :
|
|---|
| 816 | * Result :
|
|---|
| 817 | * Remark : NTDLL.939
|
|---|
| 818 | * Status :
|
|---|
| 819 | *
|
|---|
| 820 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 821 | *****************************************************************************/
|
|---|
| 822 |
|
|---|
| 823 | size_t CDECL OS2wcslen(const wchar_t* str)
|
|---|
| 824 | {
|
|---|
| 825 | dprintf(("NTDLL: wcslen(%08xh)\n",
|
|---|
| 826 | str));
|
|---|
| 827 |
|
|---|
| 828 | return (wcslen(str));
|
|---|
| 829 | }
|
|---|
| 830 |
|
|---|
| 831 |
|
|---|
| 832 | /*****************************************************************************
|
|---|
| 833 | * Name :
|
|---|
| 834 | * Purpose :
|
|---|
| 835 | * Parameters:
|
|---|
| 836 | * Variables :
|
|---|
| 837 | * Result :
|
|---|
| 838 | * Remark : NTDLL.940
|
|---|
| 839 | * Status :
|
|---|
| 840 | *
|
|---|
| 841 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 842 | *****************************************************************************/
|
|---|
| 843 |
|
|---|
| 844 | wchar_t* CDECL OS2wcsncat( wchar_t* str1,
|
|---|
| 845 | const wchar_t* str2,
|
|---|
| 846 | size_t i)
|
|---|
| 847 | {
|
|---|
| 848 | dprintf(("NTDLL: wcsncat(%08xh,%08xh,%08xh)\n",
|
|---|
| 849 | str1,
|
|---|
| 850 | str2,
|
|---|
| 851 | i));
|
|---|
| 852 |
|
|---|
| 853 | return (wcsncat(str1, str2, i));
|
|---|
| 854 | }
|
|---|
| 855 |
|
|---|
| 856 |
|
|---|
| 857 | /*****************************************************************************
|
|---|
| 858 | * Name :
|
|---|
| 859 | * Purpose :
|
|---|
| 860 | * Parameters:
|
|---|
| 861 | * Variables :
|
|---|
| 862 | * Result :
|
|---|
| 863 | * Remark : NTDLL.941
|
|---|
| 864 | * Status :
|
|---|
| 865 | *
|
|---|
| 866 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 867 | *****************************************************************************/
|
|---|
| 868 |
|
|---|
| 869 | int CDECL OS2wcsncmp(const wchar_t* str1,
|
|---|
| 870 | const wchar_t* str2,
|
|---|
| 871 | size_t i)
|
|---|
| 872 | {
|
|---|
| 873 | dprintf(("NTDLL: wcsncmp(%08xh,%08xh,%08xh)\n",
|
|---|
| 874 | str1,
|
|---|
| 875 | str2,
|
|---|
| 876 | i));
|
|---|
| 877 |
|
|---|
| 878 | return (wcsncmp(str1, str2, i));
|
|---|
| 879 | }
|
|---|
| 880 |
|
|---|
| 881 |
|
|---|
| 882 | /*****************************************************************************
|
|---|
| 883 | * Name :
|
|---|
| 884 | * Purpose :
|
|---|
| 885 | * Parameters:
|
|---|
| 886 | * Variables :
|
|---|
| 887 | * Result :
|
|---|
| 888 | * Remark : NTDLL.942
|
|---|
| 889 | * Status :
|
|---|
| 890 | *
|
|---|
| 891 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 892 | *****************************************************************************/
|
|---|
| 893 |
|
|---|
| 894 | wchar_t* CDECL OS2wcsncpy( wchar_t* str1,
|
|---|
| 895 | const wchar_t* str2,
|
|---|
| 896 | size_t i)
|
|---|
| 897 | {
|
|---|
| 898 | dprintf(("NTDLL: wcsncpy(%s,%s,%08xh)\n",
|
|---|
| 899 | str1,
|
|---|
| 900 | str2,
|
|---|
| 901 | i));
|
|---|
| 902 |
|
|---|
| 903 | return (wcsncpy(str1, str2, i));
|
|---|
| 904 | }
|
|---|
| 905 |
|
|---|
| 906 |
|
|---|
| 907 | /*****************************************************************************
|
|---|
| 908 | * Name :
|
|---|
| 909 | * Purpose :
|
|---|
| 910 | * Parameters:
|
|---|
| 911 | * Variables :
|
|---|
| 912 | * Result :
|
|---|
| 913 | * Remark : NTDLL.943
|
|---|
| 914 | * Status :
|
|---|
| 915 | *
|
|---|
| 916 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 917 | *****************************************************************************/
|
|---|
| 918 |
|
|---|
| 919 | wchar_t* CDECL OS2wcspbrk(const wchar_t* str1,
|
|---|
| 920 | const wchar_t* str2)
|
|---|
| 921 | {
|
|---|
| 922 | dprintf(("NTDLL: wcspbrk(%08xh,%08xh)\n",
|
|---|
| 923 | str1,
|
|---|
| 924 | str2));
|
|---|
| 925 |
|
|---|
| 926 | return (wcspbrk(str1, str2));
|
|---|
| 927 | }
|
|---|
| 928 |
|
|---|
| 929 |
|
|---|
| 930 | /*****************************************************************************
|
|---|
| 931 | * Name :
|
|---|
| 932 | * Purpose :
|
|---|
| 933 | * Parameters:
|
|---|
| 934 | * Variables :
|
|---|
| 935 | * Result :
|
|---|
| 936 | * Remark : NTDLL.944
|
|---|
| 937 | * Status :
|
|---|
| 938 | *
|
|---|
| 939 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 940 | *****************************************************************************/
|
|---|
| 941 |
|
|---|
| 942 | wchar_t* CDECL OS2wcsrchr(const wchar_t* str,
|
|---|
| 943 | size_t i)
|
|---|
| 944 | {
|
|---|
| 945 | dprintf(("NTDLL: wcsrchr(%08xh,%08xh)\n",
|
|---|
| 946 | str,
|
|---|
| 947 | i));
|
|---|
| 948 |
|
|---|
| 949 | return (wcsrchr(str, i));
|
|---|
| 950 | }
|
|---|
| 951 |
|
|---|
| 952 |
|
|---|
| 953 | /*****************************************************************************
|
|---|
| 954 | * Name :
|
|---|
| 955 | * Purpose :
|
|---|
| 956 | * Parameters:
|
|---|
| 957 | * Variables :
|
|---|
| 958 | * Result :
|
|---|
| 959 | * Remark : NTDLL.945
|
|---|
| 960 | * Status :
|
|---|
| 961 | *
|
|---|
| 962 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 963 | *****************************************************************************/
|
|---|
| 964 |
|
|---|
| 965 | size_t CDECL OS2wcsspn(const wchar_t* str1,
|
|---|
| 966 | const wchar_t* str2)
|
|---|
| 967 | {
|
|---|
| 968 | dprintf(("NTDLL: wcsspn(%08xh,%08xh)\n",
|
|---|
| 969 | str1,
|
|---|
| 970 | str2));
|
|---|
| 971 |
|
|---|
| 972 | return (wcsspn(str1, str2));
|
|---|
| 973 | }
|
|---|
| 974 |
|
|---|
| 975 |
|
|---|
| 976 | /*****************************************************************************
|
|---|
| 977 | * Name :
|
|---|
| 978 | * Purpose :
|
|---|
| 979 | * Parameters:
|
|---|
| 980 | * Variables :
|
|---|
| 981 | * Result :
|
|---|
| 982 | * Remark : NTDLL.946
|
|---|
| 983 | * Status :
|
|---|
| 984 | *
|
|---|
| 985 | * Author : Patrick Haller [Thu, 1999/06/22 20:44]
|
|---|
| 986 | *****************************************************************************/
|
|---|
| 987 |
|
|---|
| 988 | wchar_t* CDECL OS2wcsstr(const wchar_t* str1,
|
|---|
| 989 | const wchar_t* str2)
|
|---|
| 990 | {
|
|---|
| 991 | dprintf(("NTDLL: wcsstr(%s,%s)\n",
|
|---|
| 992 | str1,
|
|---|
| 993 | str2));
|
|---|
| 994 |
|
|---|
| 995 | return (wcsstr(str1, str2));
|
|---|
| 996 | }
|
|---|
| 997 |
|
|---|