Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of MODSERIAL by
Diff: MODSERIAL.cpp
- Revision:
- 42:4737f8a5b018
- Parent:
- 31:b90b20f78f04
diff -r d8422efe4761 -r 4737f8a5b018 MODSERIAL.cpp
--- a/MODSERIAL.cpp Tue Nov 17 12:11:44 2015 -0300
+++ b/MODSERIAL.cpp Mon Sep 12 12:07:22 2016 +0000
@@ -94,13 +94,13 @@
bool MODSERIAL::claim (FILE *stream) {
- if ( _name == NULL) {
+ if ( FileBase::getName() == NULL) {
error("claim requires a name to be given in the instantiator of the MODSERIAL instance!\r\n");
}
//Add '/' before name:
- char *path = new char[strlen(_name) + 2];
- sprintf(path, "/%s", _name);
+ char *path = new char[strlen(FileBase::getName()) + 2];
+ sprintf(path, "/%s", FileBase::getName());
if (freopen(path, "w", stream) == NULL) {
// Failed, should not happen
