Skip to content

Always let server/renderer run in Win32 Jobs#1379

Merged
hiroyuki-komatsu merged 1 commit into
google:masterfrom
yukawa:issue_1376
Oct 17, 2025
Merged

Always let server/renderer run in Win32 Jobs#1379
hiroyuki-komatsu merged 1 commit into
google:masterfrom
yukawa:issue_1376

Conversation

@yukawa
Copy link
Copy Markdown
Collaborator

@yukawa yukawa commented Sep 30, 2025

Description

As the initial step towards removing "restricted mode" (#1376), this commit simplifies the codebase by taking advantage of the fact that Windows 8 and later allows Win32 processes to belong to multiple jobs.

Before Windows 8, Win32 processes cannot belong to multiple jobs. Due to this limitation, there is a case when mozc_{server,renderer} cannot be launched in a restricted job. This is why WinSandboxSecurityInfo::use_locked_down_job has been determined at runtime with RunLevel::IsProcessInJob().

Now that Mozc only supports Windows 10 and later, use_locked_down_job can be initialized as the compile time constant.

To minimize the compatibility impact, CREATE_BREAKAWAY_FROM_JOB flag continues to be specified if possible. This means that when Mozc server/renderer is launched from a process in a job which allows breakaway, the user observable behavior remains unchanged before and after this commit.

Issue IDs

Steps to test new behaviors

  • OS: Windows 11 24H2
  • Steps:
    1. Build and install Mozc
    2. Open Notepad
    3. Confirm you can still enable Mozc and use it.

@yukawa
Copy link
Copy Markdown
Collaborator Author

yukawa commented Oct 2, 2025

Converting this to draft to make it clear that #1368 needs to be merged first to avoid merge conflict.

@yukawa yukawa marked this pull request as draft October 2, 2025 08:04
As the initial step towards removing "restricted mode" (google#1376), this
commit simplifies the codebase by taking advantage of the fact that
Windows 8 and later allows Win32 processes to belong to multiple jobs.

Before Windows 8, Win32 processes cannot belong to multiple jobs. Due to
this limitation, there is a case when mozc_{server,renderer} cannot be
launched in a restricted job. This is why

  WinSandboxSecurityInfo::use_locked_down_job

has been determined at runtime with RunLevel::IsProcessInJob().

Now that Mozc only supports Windows 10 and later, use_locked_down_job
can be initialized as the compile time constant.

To minimize the compatibility impact, CREATE_BREAKAWAY_FROM_JOB flag
continues to be specified if possible. This means that when Mozc
server/renderer is launched from a process in a job which allows
breakaway, the user observable behavior remains unchanged before and
after this commit.
@yukawa yukawa marked this pull request as ready for review October 8, 2025 07:20
@yukawa
Copy link
Copy Markdown
Collaborator Author

yukawa commented Oct 8, 2025

Rebased on top of ff6a842. Now this is ready to be reviewed.

@hiroyuki-komatsu hiroyuki-komatsu merged commit ca34c8d into google:master Oct 17, 2025
2 checks passed
@yukawa yukawa deleted the issue_1376 branch October 19, 2025 11:09
hiroyuki-komatsu added a commit that referenced this pull request Oct 22, 2025
2.32.5981 → 2.32.5994

Conversion

* Do not remember punctuation-ending non-Japanese (ASCII) strings directly input by the composer. (5e09d3d)

Feature

* Stop providing "did you mean" description on language aware rewriter. (353859a)

Bug fix

* Windows: Fix text reconversions on Excel (#1385)
* Windows: Avoid flickering of composing text on Windows (#1389)

Code

* Windows: Always let server/renderer run in Win32 Jobs (#1379)

2.31.5851 → 2.32.5981

Conversion

* Updated the language model (11a5dc3)
* Updated zip-code as of 2025-08-30 (53e6db7)
* Removed the 62-day storage limit for input history. Retain the history up to the data size limit. (12f6d98)
* Fix an overfiltering of candidates that have the same key and longer common prefix value. (1dfd91b)
  + e.g. 堺 (さかい) was overfilitered as 堺井(さかい) is also an candidate.
* Updated some data entries (#1331, #1351, #1360, #1374)
* Updated the candidate filtering rule (9d7332c)
* Updated the logic of word suggestion for multiple segments (aka inner boundary) (22adec5)

Bug fix

* Fix an issue that the top candidate with multiple segments may get broken. (f3437a0)
* Linux: Fix a crash issue on some Linux environment that does not support _SC_GETPW_R_SIZE_MAX (#1318)
* macOS: Fix a crash issue of the installer on macOS 26 (Tahoe) (018d8d9)
* Windows: Fix a UI issue that mouse clicking on the candidate window did not work. (#1372)
  + Regression on 2.31.5851

Packaging

* Support specifying the version number as a Bazel command line option (4f48688)
  * e.g. Bazel build package --action_env=MOZC_VERSION="2.31.5810.0"
* Android: made libmozc.so compatible with 16 KB page sizes (#1364)
* macOS: supported .dmg file generation with codesign
* macOS: updated the required version from macOS11 to macOS12
* Windows: Supported ARM64 build (#1130)
* Windows: Removed unused PDB (#1261)
* Windows: Support OS build number check (#1329)

Build

* Removed the build time dependency on Unicode's text files (#1353)
* Updated Bazel: 8.1.1 → 8.4.1
* Updated Abseil: 20250127.1→ 20250814.0
* Updated Protobuf: v29.3 → v32.0
* Updated googletest: v1.15.2 → v1.17.0
* Updated Qt: 6.8.0 → 6.9.1
* GitHub Actions: updated macOS environment 14 → 15
* GitHub Actions: updated Windows environment 2022 → 2025

Code

* Added lattice viewer (3c62c59)
* Updated the coding style (i.e. "string &s" → "string& s").
* Performed a number of refactoring.

PiperOrigin-RevId: 822376409
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.

2 participants