Changeset 8584 for trunk/src/shlwapi/string.c
- Timestamp:
- Jun 7, 2002, 10:02:20 AM (23 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/shlwapi/string.c
r7820 r8584 1 /* 2 * Shlwapi string functions 3 * 4 * Copyright 1998 Juergen Schmied 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either 9 * version 2.1 of the License, or (at your option) any later version. 10 * 11 * This library is distributed in the hope that it will be useful, 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 * Lesser General Public License for more details. 15 * 16 * You should have received a copy of the GNU Lesser General Public 17 * License along with this library; if not, write to the Free Software 18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 */ 20 1 21 #include <ctype.h> 2 #include <stdlib.h> 22 #include <stdlib.h> 3 23 #include <stdio.h> 4 24 #include <string.h> … … 10 30 #include "winuser.h" 11 31 #include "winreg.h" 12 #ifdef __WIN32OS2__13 #include "shlobj.h"14 #define NO_SHLWAPI_STREAM15 #include "shlwapi.h"16 #else17 32 #define NO_SHLWAPI_STREAM 18 33 #include "shlwapi.h" 19 34 #include "shlobj.h" 20 #endif21 35 #include "wine/unicode.h" 22 #include " debugtools.h"23 24 DEFAULT_DEBUG_CHANNEL(shell);36 #include "wine/debug.h" 37 38 WINE_DEFAULT_DEBUG_CHANNEL(shell); 25 39 26 40 /************************************************************************* … … 255 269 int len = strlen(lpSrc); 256 270 LPSTR lpDest = (LPSTR) LocalAlloc(LMEM_FIXED, len+1); 257 271 258 272 TRACE("%s\n", lpSrc); 259 273 … … 269 283 int len = strlenW(lpSrc); 270 284 LPWSTR lpDest = (LPWSTR) LocalAlloc(LMEM_FIXED, sizeof(WCHAR) * (len+1)); 271 285 272 286 TRACE("%s\n", debugstr_w(lpSrc)); 273 287 … … 295 309 } 296 310 } 297 } 311 } 298 312 TRACE("-- %u\n", pos); 299 return pos; 313 return pos; 300 314 } 301 315 … … 319 333 } 320 334 } 321 } 335 } 322 336 TRACE("-- %u\n", pos); 323 return pos; 337 return pos; 324 338 } 325 339 … … 342 356 if (dbcs && lpStart[1] != HIBYTE(wMatch)) continue; 343 357 lpGotIt = lpStart; 344 } 358 } 345 359 return (LPSTR)lpGotIt; 346 360 } … … 390 404 if (toupper(*lpStart) == toupper(wMatch)) lpGotIt = lpStart; 391 405 } 392 } 406 } 393 407 return (LPSTR)lpGotIt; 394 408 } … … 452 466 /************************************************************************* 453 467 * StrRetToBufA [SHLWAPI.@] 454 * 468 * 455 469 * converts a STRRET to a normal string 456 470 * … … 497 511 /************************************************************************* 498 512 * StrRetToBufW [SHLWAPI.@] 499 * 513 * 500 514 * converts a STRRET to a normal string 501 515 * … … 564 578 } 565 579 lstrcpynA (pszBuf, buf, cchBuf); 566 return pszBuf; 580 return pszBuf; 567 581 } 568 582 … … 621 635 return trimmed; 622 636 } 623 624 /*************************************************************************625 * wnsprintfA [SHLWAPI.@]626 */627 int WINAPIV wnsprintfA(LPSTR lpOut, int cchLimitIn, LPCSTR lpFmt, ...)628 {629 va_list valist;630 INT res;631 632 va_start( valist, lpFmt );633 res = wvsnprintfA( lpOut, cchLimitIn, lpFmt, valist );634 va_end( valist );635 return res;636 }637 638 /*************************************************************************639 * wnsprintfW [SHLWAPI.@]640 */641 int WINAPIV wnsprintfW(LPWSTR lpOut, int cchLimitIn, LPCWSTR lpFmt, ...)642 {643 va_list valist;644 INT res;645 646 va_start( valist, lpFmt );647 res = wvsnprintfW( lpOut, cchLimitIn, lpFmt, valist );648 va_end( valist );649 return res;650 }
Note:
See TracChangeset
for help on using the changeset viewer.