Skip to content

Conversation

@nuertey
Copy link
Contributor

@nuertey nuertey commented Jan 13, 2019

Changelog :
[1] Ensuring that resources (variables, threads, etc.) are created only at the point when needed.

[2] Ensuring that both threads cooperate better and in writing output to the Serial Terminal.

[3] Resolving memory leaks.

[4] Minor cleanups for code readability.

[1] Ensuring that resources (variables, threads, etc.) are created only at the point when needed.

[2] Ensuring that both threads cooperate better and in writing output to the Serial Terminal.

[3] Resolving memory leaks.

[4] Minor cleanups for code readability.
@deepikabhavnani
Copy link

@nuertey - This PR will need a rebase and minor formatting change.

@nuertey
Copy link
Contributor Author

nuertey commented Jan 15, 2019

@deepikabhavnani , I reverted all those formatting changes as asked and pushed it to my fork. Let me know if I missed any or went through the wrong process to do so.

@nuertey
Copy link
Contributor Author

nuertey commented Jan 15, 2019

Okay @deepikabhavnani, the formatting should be all taken care of now per the coding standard.

@deepikabhavnani
Copy link

Some conflicts which should be resolved

@nuertey
Copy link
Contributor Author

nuertey commented Jan 15, 2019

Essentially you want to remove the stdio_mutex then? Note that without the mutex, the output being issued by both threads becomes garbled on the serial terminal. That was one of the original fixes that called for the mutex. Do you want me to try removing that and then testing again to see if perhaps it is better now, what with all the other changes?

@deepikabhavnani
Copy link

deepikabhavnani commented Jan 15, 2019

Essentially you want to remove the stdio_mutex then?

No mutex is good. In order to resolve conflicts you will have to rebase your PR commits on top of upstream master to resolve conflicts. I will not be able to merge with conflicted code, in resolution you can select your code and pick master changes if missed by your commit


<<<<<<< master
        stdio_mutex.lock();
        printf("sent %d [%.*s]\n", result, strstr(sbuffer, "\r\n") - sbuffer, sbuffer);
        stdio_mutex.unlock();
=======
        printf("sent %d [%.*s]\n", result, strstr(sbuffer, "\r\n") - sbuffer, sbuffer);
>>>>>>> master

Will resolve into

        stdio_mutex.lock();
        printf("sent %d [%.*s]\n", result, strstr(sbuffer, "\r\n") - sbuffer, sbuffer);
        stdio_mutex.unlock();

@nuertey
Copy link
Contributor Author

nuertey commented Jan 15, 2019

Thanks. I hope I got it now. I am fairly new to the github workflow so still learning some of the process as I encounter them.

@deepikabhavnani
Copy link

Thanks. I hope I got it now. I am fairly new to the github workflow so still learning some of the process as I encounter them.

Merge is another way of resolving conflicts. In mbed-os repo merges are not allowed and we suggest to do git rebase instead, you can explore that. But change is fine for this repo 👍

@deepikabhavnani deepikabhavnani merged commit 6ea9aa2 into ARMmbed:master Jan 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants