Skip to content

Conversation

@ZackerySpytz
Copy link
Contributor

@ZackerySpytz ZackerySpytz commented May 17, 2019

The final addition (cur += step) may overflow, so use size_t for "cur".
"cur" is always positive (even for negative steps), so it is safe to use
size_t here.

Co-Authored-By: Martin Panter [email protected]

https://bugs.python.org/issue36946

The final addition (cur += step) may overflow, so use size_t for "cur".
"cur" is always positive (even for negative steps), so it is safe to use
size_t here.

Co-Authored-By: Martin Panter <[email protected]>
@miss-islington
Copy link
Contributor

Thanks @ZackerySpytz for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.7.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request May 17, 2019
…pythonGH-13375)

The final addition (cur += step) may overflow, so use size_t for "cur".
"cur" is always positive (even for negative steps), so it is safe to use
size_t here.

Co-Authored-By: Martin Panter <[email protected]>
(cherry picked from commit 14514d9)

Co-authored-by: Zackery Spytz <[email protected]>
@bedevere-bot
Copy link

GH-13376 is a backport of this pull request to the 3.7 branch.

miss-islington added a commit that referenced this pull request May 17, 2019
…GH-13375)

The final addition (cur += step) may overflow, so use size_t for "cur".
"cur" is always positive (even for negative steps), so it is safe to use
size_t here.

Co-Authored-By: Martin Panter <[email protected]>
(cherry picked from commit 14514d9)

Co-authored-by: Zackery Spytz <[email protected]>
@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure ⚠️⚠️⚠️

Hi! The buildbot AMD64 Ubuntu Shared 3.x has failed when building commit 14514d9.

What do you need to do:

  1. Don't panic.
  2. Check the buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/141/builds/1747) and take a look at the build logs.
  4. Check if the failure is related to this commit (14514d9) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/141/builds/1747

Click to see traceback logs
From https://github.com/python/cpython
 * branch                  master     -> FETCH_HEAD
Reset branch 'master'

test_turtle skipped -- No module named '_tkinter'
test_ttk_textonly skipped -- No module named '_tkinter'
test_ioctl skipped -- Unable to open /dev/tty
test_ttk_guionly skipped -- No module named '_tkinter'
test_kqueue skipped -- test works only on BSD
test_devpoll skipped -- test works only on Solaris OS family
test_tix skipped -- No module named '_tkinter'
test_ossaudiodev skipped -- [Errno 2] No such file or directory: '/dev/dsp'
test_idle skipped -- No module named '_tkinter'
test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run
test_flock (__main__.FNTLEINTRTest) ... ok
test_lockf (__main__.FNTLEINTRTest) ... ok
test_read (__main__.OSEINTRTest) ... ok
test_wait (__main__.OSEINTRTest) ... ok
test_wait3 (__main__.OSEINTRTest) ... ok
test_wait4 (__main__.OSEINTRTest) ... ok
test_waitpid (__main__.OSEINTRTest) ... ok
test_write (__main__.OSEINTRTest) ... ok
test_devpoll (__main__.SelectEINTRTest) ... skipped 'need select.devpoll'
test_epoll (__main__.SelectEINTRTest) ... ok
test_kqueue (__main__.SelectEINTRTest) ... skipped 'need select.kqueue'
test_poll (__main__.SelectEINTRTest) ... ok
test_select (__main__.SelectEINTRTest) ... ok
test_sigtimedwait (__main__.SignalEINTRTest) ... ok
test_sigwaitinfo (__main__.SignalEINTRTest) ... ok
test_accept (__main__.SocketEINTRTest) ... ok
test_open (__main__.SocketEINTRTest) ... ok
test_os_open (__main__.SocketEINTRTest) ... ok
test_recv (__main__.SocketEINTRTest) ... ok
test_recvmsg (__main__.SocketEINTRTest) ... ok
test_send (__main__.SocketEINTRTest) ... ok
test_sendall (__main__.SocketEINTRTest) ... ok
test_sendmsg (__main__.SocketEINTRTest) ... ok
test_sleep (__main__.TimeEINTRTest) ... ok

----------------------------------------------------------------------
Ran 24 tests in 7.663s

OK (skipped=2)
BDB0111 DB->del: attempt to modify a read-only database
BDB0111 DB->del: attempt to modify a read-only database
BDB0111 DB->put: attempt to modify a read-only database
test_startfile skipped -- object <module 'os' from '/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/os.py'> has no attribute 'startfile'
test_winsound skipped -- No module named 'winsound'
stty: 'standard input': Inappropriate ioctl for device
test_tcl skipped -- No module named '_tkinter'
test_winreg skipped -- No module named 'winreg'
test_msilib skipped -- No module named '_msi'
BDB0004 fop_read_meta: @test_7987_tmp_ndbm.db: unexpected file type or format
test_winconsoleio skipped -- test only relevant on win32
test_tk skipped -- No module named '_tkinter'
Terminated
make: *** [buildbottest] Error 143

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip news type-bug An unexpected behavior, bug, or error

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants