Many developers for Windows used to fact that all resources that you allocated in your application will be released when your process is closed. And in fact, many developers read Windows API function description by diagonal ignoring most of it. Please read it carefully and I will explain why.

Few years ago, developers started to hit the same problem: application failed to start with some stupid unrelated error and in fact all application failed to start again with some strange error. Restart always fixes this problem, so we blamed Microsoft and move on. In some cases, you even cannot restart your PC due to the same strange errors. But we time it start to happen more and more often. And

As you know from my previous post that Microsoft updated Skype and they did it quite badly. They added few critical features to new version but still looks quite bad. I still staying on latest version I could find (7.41.0.101) until it will stop working completely.

And recently I realized that my version slowly begins to behave incorrectly. One of the biggest issues right now that in conversation instead of:
Some person: Text1
                me: My reply 1
Some person: Text2
                me: My reply 2
Some person: Text3
                me: My reply 3

I can see it like this:
Some person: Text1
Some person: Text2
Some person: Text3

If you are developer, you should never use anything related to current directory. If you do, then with almost 100% probability you will regret that you did. Let me explain why you should never use it.

Current directory is state of your process. And it is not read only. Some code in your process can change it. And imagine you tested your code and made sure that it is safe to use current directory in that particular place. But tomorrow you or someone in your team will  refactor this code and move it in different part that it is not safe. For example, move that code to function that executes in different thread or threads. Good luck debugging that.

But

It amazes me again and again when you didn’t change anything, but things started to work differently.

That what happened to me recently. Few days ago, I realized that in many places’ popup menu popped up to the left from mouse pointer like on the picture:

This was picture from Outlook, but other Office applications works the same.

At first it looked strange and unusual. I didn’t pay much attention but with time it became a bit annoying. My muscle memory tells me that something is wrong, but brain continues and clicks on menu in unusual place.

Then I started to see it on my work PC. And finally, I decided to

Just some history. I bought Samsung 850 EVO 500GB for $157.99 in September 9, 2016. I bought Samsung 860 EVO500 GB for $117.99 in July 31, 2018 and now it cost $79.99 (https://www.amazon.com/Samsung-500GB-Internal-MZ-76E500B-AM/dp/B0781Z7Y3S).

It is quite big price drop for few months. Now 1TB cost $147.99  (https://www.amazon.com/Samsung-Inch-Internal-MZ-76E1T0B-AM/dp/B078DPCY3T) and this is less than I spent on 500GB 2 years ago.

And keep in mind that Samsung is one of the leaders of SSD market and if you are planning to buy SSD I recommend Samsung 860 EVO 1TB because it is a bit faster than 500GB. There are not many usages that will require more storage so it should be enough for quite some time specially if you

This is interesting story about problem I was able to solve and how correlation does not always imply causation.

Ok, sometime ago my wife dropped her iPhone and broke screen. Initially I thought to repair it via 3rd party service but at the end I went to Apple and for $120 they did replace screen. And as story unfold you will see that it was totally worth it.

Few days later after Apple fixed screen (and it took only one hour) my wife started to complain that phone is started to freeze for few seconds. And after few days it became quite bad. So, I did backup phone and my wife went to Apple and they simply replace phone to

At the beginning I would like to clarify on details of Windows message queue. Many people believe that InvalidateRect function (or any other action that makes your window have update region) will actually post WM_PAINT message into message queue. Similarly, they believe that any mouse movement will leads to insert of WM_MOUSEMOVE (and corresponding messages like WM_HCHITTEST). But in reality, it is quite different (unless there is call to PeekMessage with PM_NOREMOVE). It is not important from processing these messages but very important to understand these details to troubleshoot any problems.

When part of window is invalidated Windows will simply set flag that indicates that window needs painting and that’s it. There is nothing inserted at message queue at all.

Today I accidentally found solution for problem that annoying me for years (literally). And I would like to share it.

Problem

Problem was that I cannot print anything at my work from Microsoft Word and Firefox. I use Firefox as my main browser and sometimes (not that often) I have to print from Microsoft Word. And there is no error or similar. Just printer icon pops up for few seconds stating that there is nothing to print and that’s it. I can print from PDF viewer or from another browser but not from Firefox. And it was annoying me a lot. Few times I did something important in Firefox that I have to print, and I cannot open it on

Because I’m IT guy in family usually I have to fix everything related to computers. And once I have to do something on notebook with Windows 10 Home. To be honest I hate working on notebook. They all have different keyboard and trackpads, so it is taking a lot of time to get used to. They are slow and have single small screen. So, I decided to be smart and to use my home computer to connect to that notebook via Remote Desktop. But then I found that Windows 10 Home edition does not have support for Remote Desktop. Huge disappointment. But I didn’t give up. After searching internet, I found nice solution.

There is project https://github.com/stascorp/rdpwrap/blob/master/README.md that can