diff --git a/utils/MTP/MTP_DLL.dll b/utils/MTP/MTP_DLL.dll index f3436e049c..3f9b6c7a50 100755 Binary files a/utils/MTP/MTP_DLL.dll and b/utils/MTP/MTP_DLL.dll differ diff --git a/utils/MTP/MTP_DLL/sendfirm_win.cpp b/utils/MTP/MTP_DLL/sendfirm_win.cpp index 9a46e51cbd..e895c024fd 100644 --- a/utils/MTP/MTP_DLL/sendfirm_win.cpp +++ b/utils/MTP/MTP_DLL/sendfirm_win.cpp @@ -127,15 +127,15 @@ __declspec(dllexport) bool send_fw(LPWSTR file, int filesize) if(SUCCEEDED(hr) || hr == WMDM_S_NOT_ALL_PROPERTIES_APPLIED || hr == WMDM_S_NOT_ALL_PROPERTIES_RETRIEVED) + { return_value = true; + hr = S_FALSE; + } } } } } } - /* move to next Storage */ - if(!return_value) - hr = pIEnumStorage->Next(1, (IWMDMStorage **)&pIStorage, &ulNumFetched); } pIEnumStorage->Release(); } @@ -159,32 +159,3 @@ __declspec(dllexport) bool send_fw(LPWSTR file, int filesize) return return_value; } } - -/* - * Example code: - -#include -int filesize(char* filename) -{ - FILE* fd; - int tmp; - fopen_s(&fd, filename, "r"); - fseek(fd, 0, SEEK_END); - tmp = ftell(fd); - fclose(fd); - return tmp; -} - -__declspec(dllimport) bool send_fw(LPWSTR file, int filesize); - -int _tmain(int argc, char* argv[]) -{ - printf("Sending %s [%d]...\n", "Zlant.bin", filesize("Zlant.bin")); - if(send_fw(L"Zlant.bin", filesize("Zlant.bin"))) - printf("Transmitting succesfull!\n"); - else - printf("Transmitting failed!\n"); - return 0; -} - - */ diff --git a/utils/MTP/sendfirm.exe.manifest b/utils/MTP/sendfirm.manifest old mode 100755 new mode 100644 similarity index 100% rename from utils/MTP/sendfirm.exe.manifest rename to utils/MTP/sendfirm.manifest diff --git a/utils/MTP/sendfirm_win.c b/utils/MTP/sendfirm_win.c old mode 100755 new mode 100644