This Blog is first of all memos for me!! From time to time I get exposed to new and cool stuff for developers and architects ,most of the time its a solution for a problem or tips or tricks, so, I would like to track my memos and share it with you, it can save your time and nervous, I hope you will enjoy it - by Yaniv Tzanany.
Search This Blog
Tuesday, January 9, 2024
Monday, March 27, 2023
Debugging C++ , with VSCode & GDB command ( improve loading performance tip for heavy projects)
Its all about symbols that loaded into memory in the debug process.
sometimes moving with F10 takes time , and looks like vscode screen is freezing.
to fix this issue and get much better vscode debug performance follow the next steps:
add to launch.json file as follow the next section, make sure in the exceptionList you have your brand so file .
the section below prevent loading extra symbols that you don't need to debug.
"loadAll": false,
"exceptionList": "libMyShared.so"
},
to work with gdb command line make sure all the symbolic will not loaded , the default is ON.
the next parameter control such behavior
in gdb type 'set auto-solib-add off' - disabled loading any symbolic files.
you can start your program
and when your SO files loaded , you can CTRL-C
and use the share command to load your so symbolic file.
share /path/mysofile.so
option 2 : put in your program the next line
__asm__ volatile("int $0x03");
its will break into your gdb and use share command to load your symbolic .
Advanced Debugging with GDB - nice video
enjoy
Yaniv Tzanany
Monday, March 20, 2023
C++ custom debugger view for VisualCode
you can add custom view for debugger.
https://www.cppstories.com/2021/natvis-tutorial/
https://devblogs.microsoft.com/cppblog/debug-visualizers-in-visual-c-2015/
create into your root folder xxx.natvis
make sure in the launch.json to add
more sample:
note:
the Name of the class must be full qualified e.g. contain namespace name if exist.
even typedef name should be act as new Name in the natvis file.
ty
enjoy
Yaniv
sample template class:
sample template natvis file:
Wednesday, January 25, 2023
Sunday, January 1, 2023
c++ advanced tips
https://www.geeksforgeeks.org/template-metaprogramming-in-c
https://en.wikipedia.org/wiki/Memoization
Better C++14 reflections - Antony Polukhin
Reading Binary Data with Style: A Serialization Framework for C++17
https://github.com/apolukhin/magic_get
https://github.com/Neargye/magic_enum
https://github.com/neobrain/blobify
Template Normal Programming
https://www.youtube.com/watch?v=vwrXHznaYLA
"Type Deduction and Why You Care"
https://www.youtube.com/watch?v=wQxj20X-tIU
Intro to Template Metaprogramming
https://www.youtube.com/watch?v=VBI6TSo8Zog&list=PLWxziGKTUvQFIsbbFcTZz7jOT4TMGnZBh
Template Metaprogramming: Type Traits
Walter E. Brown "Modern Template Metaprogramming -- good
https://en.wikipedia.org/wiki/Template_metaprogramming
https://en.wikipedia.org/wiki/Curiously_recurring_template_pattern
Tuesday, March 1, 2022
Wednesday, February 9, 2022
Free Test tools
Have a look at this free tools , working good for QA and web testers
https://testproject.io/
Friday, January 7, 2022
Google sheets api - [The caller does not have permission] - shared sheets
In case you cant access to shared sheets via your code.
make sure to create a service account , copy the "email" for this service account.
make sure the one who shared the file, share it with your service account email.
and it should work.
working with API_KEY on shared sheets get failure.
only service account.
access to your own sheets could be done via api_key or service account.
links:
https://developers.google.com/api-client-library/dotnet/guide/aaa_oauth#web-applications-aspnet-mvc
https://cloud.google.com/docs/authentication/production
https://developers.google.com/sheets/api/quickstart/dotnet
Enjoy
Yaniv
Saturday, September 11, 2021
Wednesday, May 5, 2021
Windows tools
great tools for windows to analyze process and malware
more tools - founded at
https://github.com/avivskital/Malware-Analysis--NJrat/blob/main/Malware%20Analysis%20project.pdf
Monday, May 3, 2021
Friday, December 4, 2020
Sunday, September 27, 2020
Move GoDaddy Domain Name To Your Azure Website
very helpful tips
https://www.codeproject.com/Tips/890336/Set-Your-GoDaddy-Domain-Name-To-Your-Azure-Website#:~:text=Login%20to%20your%20account%20in,the%20window%20in%20step%204
Monday, April 20, 2020
Wednesday, April 15, 2020
Thursday, February 20, 2020
Saturday, November 30, 2019
free for developers
https://free-for.dev/#/?id=stun-webrtc-web-socket-servers-and-other-routers
Tuesday, October 22, 2019
C# Controller - accept any json in POST (not typed)
[HttpPost]
public ActionResult Bot(string request)
{
Request.InputStream.Position = 0;
var input = new StreamReader(Request.InputStream).ReadToEnd();
JObject json = JObject.Parse(input);
...........
}
Monday, September 9, 2019
Android Build Types and Product Flavors
Very good tutorial to generate few build type
https://www.journaldev.com/21533/android-build-types-product-flavors#targetText=Android%20Build%20Types,you%20to%20sign%20the%20APK.