mirror of https://github.com/arendst/Tasmota.git
Merge pull request #6418 from gemu2015/scripter-bugfix
scripter bug fix
This commit is contained in:
commit
e126faa114
|
@ -2045,6 +2045,8 @@ void Replace_Cmd_Vars(char *srcbuf,char *dstbuf,uint16_t dstsize) {
|
|||
if (isdigit(*cp)) {
|
||||
dprec=*cp&0xf;
|
||||
cp++;
|
||||
} else {
|
||||
dprec=glob_script_mem.script_dprec;
|
||||
}
|
||||
cp=isvar(cp,&vtype,&ind,&fvar,string,0);
|
||||
if (vtype!=VAR_NV) {
|
||||
|
@ -3343,7 +3345,6 @@ bool ScriptCommand(void) {
|
|||
if (XdrvMailbox.data[count]==';') XdrvMailbox.data[count]='\n';
|
||||
}
|
||||
execute_script(XdrvMailbox.data);
|
||||
Scripter_save_pvars();
|
||||
}
|
||||
}
|
||||
return serviced;
|
||||
|
@ -3735,6 +3736,7 @@ bool Xdrv10(uint8_t function)
|
|||
// assure permanent memory is 4 byte aligned
|
||||
{ uint32_t ptr=(uint32_t)glob_script_mem.script_pram;
|
||||
ptr&=0xfffffffc;
|
||||
ptr+=4;
|
||||
glob_script_mem.script_pram=(uint8_t*)ptr;
|
||||
glob_script_mem.script_pram_size-=4;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue