Please notice that forums and news and documentation have moved elsewhere.

Changeset 3bdaf18 in nscp for helpers


Ignore:
Timestamp:
04/16/11 22:51:04 (3 years ago)
Author:
Michael Medin <michael@…>
Branches:
master, 0.4.0, 0.4.1, 0.4.2
Children:
7ec3dd1
Parents:
d66ccee
Message:

Tweaks to building on linux, stil need to fix the utf8 issue and some modules...

Location:
helpers
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • helpers/installer-dlls/main_dll/installer_helper.hpp

    rb7d17f8 r3bdaf18  
    3030 
    3131  std::wstring getTargetPath(std::wstring path) { 
    32     TCHAR tmpBuf[MAX_PATH]; 
     32    wchar_t tmpBuf[MAX_PATH]; 
    3333    DWORD len = 0; 
    3434    if (MsiGetTargetPath(hInstall_ ,path.c_str(), tmpBuf, &len) != ERROR_MORE_DATA) 
     
    5757  } 
    5858  std::wstring getPropery(std::wstring path) { 
    59     TCHAR tmpBuf[MAX_PATH]; 
     59    wchar_t tmpBuf[MAX_PATH]; 
    6060    DWORD len = 0; 
    6161    if (MsiGetProperty(hInstall_ ,path.c_str(), tmpBuf, &len) != ERROR_MORE_DATA) 
     
    7070  } 
    7171  char_buffer getProperyRAW(std::wstring path) { 
    72     TCHAR emptyString[MAX_PATH]; 
     72    wchar_t emptyString[MAX_PATH]; 
    7373    DWORD len = 0; 
    7474    UINT er; 
     
    571571      return used_size() > size; 
    572572    } 
    573     operator const TCHAR* () const { 
     573    operator const wchar_t* () const { 
    574574      return buf_.c_str(); 
    575575    } 
     
    628628    DWORD id = 0; 
    629629    std::list<std::wstring> ret; 
    630     for (int i=0; ::MsiEnumProducts(i, reinterpret_cast<TCHAR*>(&buffer)) == ERROR_SUCCESS; i++) { 
     630    for (int i=0; ::MsiEnumProducts(i, reinterpret_cast<wchar_t*>(&buffer)) == ERROR_SUCCESS; i++) { 
    631631      std::wstring name = getProductName(buffer); 
    632632      ret.push_back(buffer); 
     
    638638    MsiGetProductInfo(code.c_str(), INSTALLPROPERTY_INSTALLEDPRODUCTNAME, NULL, &size); 
    639639    size++; 
    640     TCHAR *buffer = new TCHAR[size+4]; 
     640    wchar_t *buffer = new wchar_t[size+4]; 
    641641    MsiGetProductInfo(code.c_str(), INSTALLPROPERTY_INSTALLEDPRODUCTNAME, buffer, &size); 
    642642    std::wstring ret = buffer; 
  • helpers/installer-dlls/main_dll/main_dll.cpp

    rd66ccee r3bdaf18  
    385385        h.errorMessage(_T("Found old NSClient++/OP5 client installed, will uninstall it now!")); 
    386386        std::wstring command = _T("msiexec /uninstall ") + (*cit); 
    387         TCHAR *cmd = new TCHAR[command.length()+1]; 
     387        wchar_t *cmd = new wchar_t[command.length()+1]; 
    388388        wcsncpy(cmd, command.c_str(), command.length()); 
    389389        cmd[command.length()] = 0; 
  • helpers/settings_manager/CMakeLists.txt

    rd66ccee r3bdaf18  
    2323    ${NSCP_INCLUDEDIR}/charEx.h 
    2424    ${NSCP_INCLUDEDIR}/config.h 
    25     ${NSCP_INCLUDEDIR}/msvc_wrappers.h 
    2625    ${NSCP_INCLUDEDIR}/settings/macros.h 
    2726    ${NSCP_INCLUDEDIR}/settings/settings_ini.hpp 
Note: See TracChangeset for help on using the changeset viewer.