开源改变世界

在长度为 3 的关节数组中调用关节 [5] #1582

推推 grbl 3年前 (2023-01-30) 184次浏览
打开
smoe 打开了这个问题 2022 年 2 月 9 日 · 0 条评论

注释

在长度为 3 的关节数组中调用关节 [5] #1582
贡献者

cppcheck 发现了这个 – 并且是正确的:

rotatekins.c:23:21: error: Array index out of bounds; 'joints' buffer size is 24 and it is accessed at offset 40. [ctuArrayIndex]
    double c_rad = -joints[5]*M_PI/180;
                    ^
tripodkins.c:299:28: note: Calling function kinematicsForward, 1st argument is uninitialized
 if (0 != kinematicsForward(joints, &pos, &fflags, NULL)) {
                           ^
rotatekins.c:23:21: note: Using argument joints
    double c_rad = -joints[5]*M_PI/180;

免费注册 在 GitHub 上加入此对话。已有帐户? 登录评论
标签
还没有
项目

还没有

发展

没有分支机构或拉取请求

1名参加者
在长度为 3 的关节数组中调用关节 [5] #1582

喜欢 (0)